Standard deviation over recursive sample
Posted: Tue Dec 14, 2010 9:02 am
Hi!
I am using Eviews 7 and I have a question about the standard deviation function. I have a database for the period 1990Q1 to 2009Q2. I want to calculate an explanatory variable' standard deviation for the second half of my sample using the information of the first half; keeping the first observation fixed. So I want to compute it first for 1999Q4 using info from 1990Q1-1999Q3; then for 2000Q1 using info from 1990Q1-1999Q4 and so on until 2009Q2.
I have tried the programs detailed below however although it gives me information for the second half of the period (as I want to), it is calculating the standard deviation using the info. for the second half of the period instead of using the first half which is what I want.
How can I estimate the stdev for the second half of my sample using the information of the first half?
Thank you very much in advance!
!halfobs=39
!endobs=78
for !c = 1 to !halfobs
smpl @all
smpl @last-(!halfobs-!c) @last
series stdev=@stdev(a_rer_gq)
I am using Eviews 7 and I have a question about the standard deviation function. I have a database for the period 1990Q1 to 2009Q2. I want to calculate an explanatory variable' standard deviation for the second half of my sample using the information of the first half; keeping the first observation fixed. So I want to compute it first for 1999Q4 using info from 1990Q1-1999Q3; then for 2000Q1 using info from 1990Q1-1999Q4 and so on until 2009Q2.
I have tried the programs detailed below however although it gives me information for the second half of the period (as I want to), it is calculating the standard deviation using the info. for the second half of the period instead of using the first half which is what I want.
How can I estimate the stdev for the second half of my sample using the information of the first half?
Thank you very much in advance!
!halfobs=39
!endobs=78
for !c = 1 to !halfobs
smpl @all
smpl @last-(!halfobs-!c) @last
series stdev=@stdev(a_rer_gq)