Setting sample size

For questions regarding programming in the EViews programming language.

Moderators: EViews Gareth, EViews Jason, EViews Moderator, EViews Matt

fraN
Posts: 4
Joined: Fri Dec 19, 2008 5:35 am

Setting sample size

Postby fraN » Fri Jan 09, 2009 3:32 am

hi,
I am using Eview6 version and i have a sample with 2371 observation. I should create two sub-samples by using the following commands (I do not know in whic version of Eviews those commands were written):

sample s1 %first+1 %last
sample s2 %first+!q %last

So in the window command, I wrote:
sample s1 1+1 2371

...and the sample was created, then I wrote:

sample s2 1+!3 2371

after entering that command I got the following warning from Eviews "Error in Sample: !3 is not defined".
I was wondering what is the probelm and if I can get the same result by writing just 6 rather than !3 (..but i am not confident by using this last solution that is 6 rather than !3). May anyone give me any indication, please?
Thanks
francesco

startz
Non-normality and collinearity are NOT problems!
Posts: 3775
Joined: Wed Sep 17, 2008 2:25 pm

Re: Setting sample size

Postby startz » Fri Jan 09, 2009 6:07 am

fraN wrote:hi,
I am using Eview6 version and i have a sample with 2371 observation. I should create two sub-samples by using the following commands (I do not know in whic version of Eviews those commands were written):

sample s1 %first+1 %last
sample s2 %first+!q %last

So in the window command, I wrote:
sample s1 1+1 2371

...and the sample was created, then I wrote:

sample s2 1+!3 2371

after entering that command I got the following warning from Eviews "Error in Sample: !3 is not defined".
I was wondering what is the probelm and if I can get the same result by writing just 6 rather than !3 (..but i am not confident by using this last solution that is 6 rather than !3). May anyone give me any indication, please?
Thanks
francesco


Are you writing a program or typing commands in the command window?
If it's a program, you need to define the variable usinga letter rather than a number. For example, !q not !3.
If it's the command window, just type the sample you want directly,

sample s2 6 2371


Return to “Programming”

Who is online

Users browsing this forum: No registered users and 51 guests