How To Determine Weights In Weighted Least Squares In R. An optional vector of weights to be used in the fitting process.should be null or a numeric vector. 1 weighted least squares when we use ordinary least squares to estimate linear regression, we (naturally) minimize the mean squared error:

Mse(b) = 1 n xn i=1 (y i x i ) 2 (1) the solution is of course b ols= (x tx) 1xty (2) we could instead minimize the weighted mean squared error, wmse(b;w 1;:::w n) = 1 n xn i=1 w i(y i x i b) 2 (3) The weights we will use will be based on regressing the absolute residuals versus the predictor. Data in this region are given a.