I am having a problem with extracting the results from tables (in particular RESET test). I am using stepls in a loop and as expected each regression has a different number of independent variables. The problem is that the row number in the frozen table containing the statistic (or the p-value) of the RESET test keeps changing depending on the number of regressors that are included. Does anyone know how to solve this? is there another way to extract the relevant statistics from the tests?
This is the code I am using:
Code: Select all
!size=@obs(complete)
!regressions=@obs(complete)
for !y= 1 to !regressions
!x=complete(!y)
'Ramsey RESET
for !a=1 to !resettest
freeze(rtable) temp{!x}.reset(!a)
vector (!y) rt{!a}
rt{!a}(!y)=rtable(9,4)
d rtable
next
next
Many thanks!
Francisco