GLS: missing standard errors/confidence interval for fittedvalues/predict
Bug #428911 reported by
joep
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
statsmodels |
New
|
Undecided
|
Unassigned |
Bug Description
I didn't find any results for getting the prediction error for fittedvalues or for predictions made with GLS.predict. It would be nice to have standard errors that can be used to plot confidence intervals together with the fitted values.
This should be relatively easy for iid case in OLS, but maybe not so easy for heteroscedastic case (GLS, WLS) or other non-i.i.d. cases
(GLSAR doesn't have conditional or one-step ahead prediction yet.)
To post a comment you must log in.
Is the prediction error just the root mean squared error or the standard error of the regression, assuming homoskedasticity?
I never added this result explicitly though I thought about it.
If this is correct then the confidence interval of a fitted value is just
fitted_vale +/- critical_value * SER
For us SER is given by (mse_resid)**.5 or equivalently (scale)**.5
With heteroskedasticity then we just have to weight the observations?