I derive a point estimate given value $x_0$ using an estimated linear regression as follows:

$$\hat{y_0} = x_0^T\hat{\beta}.$$

I know that a prediction interval for a given value $x_0$: $$\hat{y}_0\pm t_{n-p}^{(\alpha/2)}\hat{\sigma}\sqrt{x_0^T(X^TX)^{-1}x_0 + 1},$$

where $\hat{\sigma}$ is the sample standard deviation of the residuals and $t_{n-p}^{\alpha/2}$ is a t-statistic with $n-p$ degrees of freedom at the $\alpha/2$ quantile.

I have the following question:

Thus far, I have assumed $\hat{\sigma}$ to be constant - the "standard" case. How do I estimate prediction intervals if my estimate of $\sigma$ changes when $x$ changes, e.g. instead of predicting conditional on $x_0$ $(\hat{\sigma_0})$, I predict conditional on $x_1$ $(\hat{\sigma_1})$. Here, the index may indicate changes across the cross-section or changes in time periods.

  • $\begingroup$ Related: stats.stackexchange.com/questions/352654 $\endgroup$ Nov 25, 2022 at 19:45
  • $\begingroup$ Does my answer here help you? $\endgroup$
    – statmerkur
    Nov 25, 2022 at 19:54
  • $\begingroup$ @statmerkur I am not sure - I do not see how this relates to what I was asking. But maybe I am just not seeing it. $\endgroup$
    – shenflow
    Nov 25, 2022 at 22:29
  • $\begingroup$ @Richard Hardy: If I understand your answer correctly, my line of thought ist correct? $\endgroup$
    – shenflow
    Nov 25, 2022 at 22:29
  • 1
    $\begingroup$ You need a model for the variance of the conditional response. Otherwise, you can't even construct prediction intervals for unobserved values of $x.$ $\endgroup$
    – whuber
    Nov 26, 2022 at 17:43


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.