On Mon, 31 Jan 2011, Leon Unger wrote:
that is my short script:
scalar smpl_size=25
nulldata smpl_size
scalar n = $nobs
scalar nr=100
series betas = NA
loop i=1..nr --quiet
series x_$i=randgen(u,0,100)
series v_$i=randgen(n,0,1)
series y_$i=x_$i+v_$i
ols y_$i x_$i --quiet
betas[$i]=$coeff
endloop
*delete x_* y_* v_**
series betas_norm=sqrt(n)*(betas-1)
And deleting is not performed, "because the variables are in use".
Do you know a solution?
The series are "in use" in the sense that they are referenced by
the last estimated model. You can displace that "last model" by
running a dummy regression before issuing the delete command:
ols 0 0 --quiet
delete x_* y_* v_*
Allin Cottrell