Folks,
I’m estimating a series of regressions with varying
break dates. I set up a script with the break dates in a vector, then generate
a post-break dummy variable inside a loop, like so:
<script>
matrix breaks = breaks = {1985; 1985; 1986; 1986; 1982;
…}
loop ii=4..29
post = (obs>=obsnum(breaks[$ii-3]))
(run regression, do other stuff)
end loop
</script>
This worked in an earlier version of gretl (I wrote it a
year or so ago), but now the “post” series returns all NA’s. I’ve
tried forcing breaks[$ii-3] to be an integer, but no change. I’ve played
around a bit in the console window, and things work fine if I use “post =
(obs>=obsnum(1985)),” but not otherwise. For example, trying
tmp = breaks[$ii-3]
post = (obs>=obsnum(tmp))
doesn’t work either. Any thoughts?
TIA,
PS
===============================
Dr. Peter Summers
Assistant Professor
Department of Economics
===============================