Estimating betas
Posted: Fri Apr 10, 2015 12:06 am
Hello,
How would i put this code in a loop such that it creates beta vectors not only for the ang share but also my other shares mtn, sab, sbk without rewriting the code from scratch each time.
vector(134)angbeta1
vector(134)angbeta2
for !1=1 to 134 step 1
smpl 2001.01+!1 2003.12+!1
equation eq.ls angper01 c usdzarper12 top40per01
angbeta1(!1)=@coefs(2)
angbeta2(!1)=@coefs(3)
next !1
Please help!
How would i put this code in a loop such that it creates beta vectors not only for the ang share but also my other shares mtn, sab, sbk without rewriting the code from scratch each time.
vector(134)angbeta1
vector(134)angbeta2
for !1=1 to 134 step 1
smpl 2001.01+!1 2003.12+!1
equation eq.ls angper01 c usdzarper12 top40per01
angbeta1(!1)=@coefs(2)
angbeta2(!1)=@coefs(3)
next !1
Please help!