To determine the correct code to specify, you need to know which series you want to test for heteroskedasticity. As mentioned earlier, the heteroskedasticity tests are all designed to test for heteroskedasticity in the residuals from the regression model specified in the procedures. If you specify,
y = const + beta*x ;
fit y /white breusch = (1 z1 z2);
You are testing heteroskedasticity in the residuals from the regression of y on const and x, i.e.,
residual = y - const^ - beta^*x ;
If you have already obtained residual series from the regression, or some regression somewhere, and you now specify
residual = const + beta*time ;
fit residual /white breusch=(1 time) ;
You are then testing the heteroskedasticity of the residual, call it residual2, from the regression of residual on const and time, i.e.,
residual2 = residual - const^ - beta^*time
rather than testing the heteroskedasticity in the original residual series itself.
I hope this helps.
... View more