Stack Exchange Network

Stack Exchange network consists of 175 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [weighted-regression]

Weighted least squares regression is a generalization of OLS regression used when different data points have different importance, or "weights". See also [weighted-data].

3
votes
1answer
42 views

How to fit a weighted mixed effects model?

I am looking to get help into specifying the structure of the variance matrix within the gls() function in R's nlme package (or recommendations of other packages ...
1
vote
1answer
24 views

Inverse probability weighting (IPW) with positive and negative treatments?

I am studying the effects of the government intervention which can take two directions and is usually represented as follows: $Treat = \left\{\begin{matrix} & +1 (intervene), if state A\\ &...
7
votes
3answers
234 views

Using regression weights when $Y$ might be measured with bias

Suppose we observe data $Y, X$ and would like to fit a regression model for $\mathbf{E}[Y \,|\, X]$. Unfortunately, $Y$ is sometimes measured with a systematic bias (i.e. errors whose mean is nonzero)....
2
votes
1answer
53 views

Using White's Robust Co-variance Matrix vs Weighted Least Squares to correct for heteroscedasticity

I've been trying to figure this out for a bit. How does using White's robust co-variance matrix in OLS vs weighted least squares affect mean response confidence intervals? I've experimented with ...
1
vote
1answer
29 views

What's the formula to estimate the shape parameter of Pareto distribution using weighted least squares method?

I'm trying to simulate my own method using R to estimate the shape parameter of Pareto distributed data by weighted least squares. I searched via several links of research papers, but I could not find ...
1
vote
0answers
42 views

Which is the right way to handle imbalanced data in a regression problem?

I'm working on a regression problem with imbalanced data, and I would like to know if I'm weighting the errors correctly. I'll try to illustrate the concept with a simple example. Imagine I'm ...
0
votes
0answers
18 views

How to find proper weights for summation of 3 dependent variables

I have time series for 3 variables, say energies from 3 sources (e1, e2, e3). I have checked their dependency using the calculation of the correlation of each pair and found that their dependency is ...
0
votes
1answer
56 views

weighted IV estimation by plm

I apply plm package to do fixed effects IV regression but find something which I couldn't understand. Theoretically, if we only have one endogenous variable and one IV, the IV estimator should be ...
0
votes
0answers
34 views

Risk classification with non uniform risk exposure (truncated observation period)?

I have N individuals who are exposed to a risk. The risk exposure is in year fractions (from 1/365 to 1). More or less 1/4 of the observations are exposed to the risk for an entire year. I want to ...
0
votes
0answers
11 views

Penalized regressions with forecast package and ets in R

Is there a way within the forecast package and ets to remap or penalize residuals based on some user defined function? E.g. If one wanted to impose a skew in error minimization, is this possible? ...
0
votes
0answers
38 views

Principal Component Analysis with weights

In a Principal Component setting, I want to solve the minimization problem $$\min_{\{f_t\}^T_{t=1}, \Gamma} SSR$$ where $$ SSR = \sum^T_{t=1}(y_t - \Gamma f_t)' R'_t R_t (y_t - \Gamma f_t)$$ $...
1
vote
0answers
49 views

Weighted Regression where Weights are associated with Response Variable

I am trying to carry out a simple linear regression analysis represented by the standard formulation: $$ y_i = \beta_0 + \beta_1x_i +\epsilon_i $$ However, there is an issue with my data. There is no ...
1
vote
1answer
49 views

How to use White-test to check if the heteroscedasticity has been effectively dealt with by a WLS?

Consider an OLS model with $n$ observations and $p$ explanatory variables (including an intercept term) $$y=X\beta + \epsilon$$ We may use a White test to (approximately) check for the presence of ...
1
vote
0answers
33 views

How to use weighted data in linear modeling?

I have data from studies where each study has the means for that sub sample and the sample size is n, so the n is a frequency. There is one categorical predictor. The dependent variable is a % (the % ...
1
vote
0answers
21 views

I am looking for an explanation of inference of results from weighted regression for a ratio of two continous variables.

I am performing a weighted regression for a ratio $R = \frac{Y}{X}$ using $X$ as weights. Y and X are normal and they are not independent. Is it valid to use $X$ as weights? What is the interpretation ...
2
votes
2answers
154 views

Weighted linear regression from log-likelihood?

I have 500 time-series and for each one, I compute the best (aka max likelihood) parameter α in a model that I'm testing, along with the corresponding log-likelihood. Now I wish to uncover a linear ...
0
votes
0answers
17 views

Switching attention - is there a statistical tool to mimic perceptive response?

I was driving this morning to work. Another car made sudden lane change. I noticed an interesting thing: for a brief moment my attention focused in this car. It almost physically felt that everything ...
2
votes
0answers
114 views

How to do a regression with a percent as the dependent variable and with sample mean values?

I have 60 sample of data from various studies. All I get is a mean for x and y, and a sample size. Furthermore y is a percentage. Sometimes we get the standard error of the mean. IIRC, percentages ...
1
vote
1answer
164 views

How to fit a line to data using weighted least squares (WLS) regression?

I am newbie to WLS regression topic. I am being asked to fit a line to a data using WLS. I am working in minitab. My data is as follows: cost (independent variable) (x-axis); production (dependent ...
2
votes
0answers
47 views

Standard error implications when combining IPTW and difference-in-differences

My question is about combining Inverse Probability of Treatment Weighting (IPTW) with a difference-in-difference regression with two periods (pre and post treatment). Basically, I first computed the ...
0
votes
0answers
35 views

Fitting model with error on independent variable

This is the second part of a question started here. However, as this touches a different problem inside the same overall issue I decided do separate it into two questions. I've made a series of ...
1
vote
0answers
36 views

Goodness of fit for weighted regression

Is there a goodness of fit metric similar to R^2 that can be used to evaluate a weighted regression? In my particular case, my data points are cities and I weight a regression of this data by city ...
2
votes
2answers
101 views

Which weighting to use for regression analyses at different levels of aggregation

I run a study with subjects in 400 groups of heterogeneous sizes ranging from 2 to 20 individuals. I have outcome data at the group level and at the individual level. Treatment was randomly assigned ...
1
vote
0answers
19 views

Formulating the Netwon Raphson

If this is the dataset under consideration and ...
0
votes
0answers
126 views

Does assigning “prior weights” in a binomial GLM have the same effect as maximizing a weighted likelihood?

I am doing logistic regression where there is some uncertainty about the labels for some of the points. For example, I might only be 90% sure that person 1 is actually a "Yes"--meaning I'm 10% sure ...
0
votes
1answer
23 views

Weight of variables in Regression

let's say I have a model with variables Y, X1, X2, X3 and X4. How can I tell how much each variables account for? For example, the model is Y = Bx + Bx2 + Bx3..... Now if I wanted to look at it this ...
1
vote
0answers
94 views

Meta-analysis with binary variable and weighting with sample size - Is it possible?

I am trying to conduct a meta-analysis with my data on private equity performance versus the public stock market. The binary outcome is if private equity outperforms the public stock market (Yes = 1, ...
1
vote
0answers
32 views

Misspecified regression & asymptotics

Consider the weighted regression coefficient $\hat{\beta} = (X'WX)^{-1}X'WY$ where the regression is possibly misspecified and $W$ is known. Let $\beta_* = (E[X'WX])^{-1}E[X'WY]$ and the related ...
0
votes
1answer
26 views

intercept in manually weighed regression

Why does manually weighting a regression require the intercept term to be dropped? Consider a model $$y=b_0 + b_1x + \epsilon, $$ a simple linear regression. In classically weighted regression ...
1
vote
0answers
40 views

Can analytic weights be converted into sampling weights?

I am running a linear probability model, so I know I need to correct for heteroskedasticity. Since I know the variance of the error (from theory) to be $y(\pmb x)(1-y(\pmb x))$ where $y$ is the ...
0
votes
0answers
32 views

Controlling for difficulty by weighting

I want to conduct a mixed model Anova. Essentially participants had to count the right amount of zeros from tables containing randomly generated tables of zeros and ones. Performance was measured by ...
1
vote
0answers
31 views

Correlation with adjustment

I have data from several animals that are tested daily for 15 days on the presence of seizures. I have the latency of the seizures(when it begins after the start of experiment) and they occur on some ...
1
vote
0answers
62 views

Normality and weighting scores by difficulty

I want to conduct a 2 x 3 x 2 mixed model ANOVA with Group (malus/bonus contract) as a between-subjects factor, time pressure (nine, 12 and 15 seconds) as a within-subjects factor and loss aversion (...
1
vote
0answers
26 views

Noisy Observation of Matrix of Certain Rank

Consider a rank k matrix, call it M, of size nxm. All the elements are non-negative. Now do a noisy observation of it and assume independent Poissonian errors (the error on element $M_{ij}$ is ...
1
vote
0answers
251 views

Closest approximation of a Poisson GLM using weighted least squares analysis to take into account mean/variance relationship

I have an application where I would like to approximate a Poisson GLM with identity link, i.e. a glm of the form ...
0
votes
1answer
53 views

What is the most efficient way to compute the weighted least squares estimator?

If we have the estimator $(X^{T}WX)^{-1}X^{T}Wy$ where the diagonal of W contains the inverted weights, what is the fastest/most efficient way to solve it? I know with OLS, the estimator is typically ...
1
vote
0answers
41 views

FGLS vs M estimator

I have been reading a lot that in Robust Regression, there are 2 ways of handling heteroskedasticity. 1)WLS - In SAS PROC ROBUST procedure, M estimator and Iteratively Reweighted Least Square. 2) FGLS ...
0
votes
0answers
104 views

Weighted least squares: how do I find weights

I have a dataset of the cars and their corresponding speed and distance and the R output. I am asked to find weights for the first 2 cars. First I find the residual for each car: $e_i=Y_i-\hat{Y}_i$ ...
0
votes
0answers
23 views

Finding weights and y-values in multiple linear regression?

Suppose I have observations from 15 hospitals that show its expenses, number of services offered, number of employees and the reciprocal of its average rank. I want to use these 4 independent ...
0
votes
0answers
91 views

Using sampling weights in precision, recall, etc

Suppose I take a very non-uniform sample $(x_1,y_1) ..., (x_n, y_n)$ from some population and derive sampling weights $w_1, ..., w_n$ for each sample. Next, suppose I do a logistic regression to ...
0
votes
0answers
96 views

Question concerning the weighted least squares

If the weighted least squares estimators are equal to the ordinary (unweighted) least squares estimators when when the errors have common variance $σ^2$ would it mean that the model given by the ...
1
vote
2answers
87 views

Weighted Least Squares with Endogenous Weights

Suppose I estimate the model $$y_i=\beta_0+\beta_1 x_i +\epsilon_i$$ via weighted least squares where $x_i$ and $\epsilon_i$ are independent, but I use weights $w_i$ that may be correlated with both ...
0
votes
0answers
13 views

How can I reduce the impact of frequently occurring samples in regression?

A situation I frequently encounter is that I have multiple time series of observations which I'd like to analyze using a linear regression model. The time series contain many very similar observations ...
1
vote
1answer
732 views

Difference in R-squared observed from statsmodels when WLS is used

Recently I have been trying to solve one of my problems with OLS and WLS respectively, and was trying to determine whether a weighted regression would be more suitable by comparing the R^2 value. I ...
0
votes
0answers
143 views

Using latent variable as independent variable in regression

I ran latent class analysis using poLCA package and each observation in my dataset has been assigned a class based on the highest posterior probability (modal ...
1
vote
0answers
190 views

Regression - extremely skewed response with a large, sparse matrix of boolean predictors

I'm working with a dataset that contains: $y$: the response variable that is 98% zero, but in the remaining 2% of cases it has extremely skewed real values (not integers), ranging from sub 1 to over ...
2
votes
1answer
135 views

Combine Difference-in-Differences Design with Entropy Matching

I have a pre-post/treatment-control design (diff-in-diff) with one treatment event. The data is a firm panel data set (5 pre and 5 post firm-years, ~200 firms). The problem - my treatment and control ...
1
vote
1answer
70 views

Is data-likelihood-weighted regression a thing?

Consider the basic linear regression model $y = A \theta$ with $y\in R^n$ and $A \in R^{n\times k}$ measurements and $\theta \in R^k$ parameters to be estimated. In my case, $\theta$ are physically ...
2
votes
0answers
40 views

Spatial Regression of uniformly sampled KDE

I'm trying to formulate a spatial regression, and could do with some guidance. For my independent variable, I have multiple discrete observations, each with a latitude, a longitude, and a category. ...
1
vote
0answers
332 views

Calculation of standard errors in weighted least squares (WLS)?

I'm searching for the correct calculation for a confidence interval using weighted least squares regression. Let me introduce you to my problem. Guess we have thirteen ordinal classes 1 to 13. For ...