Granger and Newbold Monte Carlo Simulation

For questions regarding programming in the EViews programming language.

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

zianhoo
Posts: 1
Joined: Tue Apr 15, 2014 4:57 am

Granger and Newbold Monte Carlo Simulation

Postby zianhoo » Tue Apr 15, 2014 5:13 am

Hi,

I am new to Eviews programming. I would like to replicate Granger and Newbold's Monte Carlo simulation for their paper on spurious regression. I wonder how this can be done in Eviews. This is what I have done so far for one replicationL

smpl @first @first
series y=0
series x=0
smpl @first+1 @last
series y = y(-1)+nrnd
series x= x(-1)+nrnd
ls y c x

How do I work in the replications and loop for 100 replications? Also, how do I collect the beta-coefficient estimates for all replications and the t-stats for all replications to plot the histograms? I would be most grateful for your advice and guidance.

Thanks in advance and have a nice day.

Al

EViews Gareth
Fe ddaethom, fe welon, fe amcangyfrifon
Posts: 13605
Joined: Tue Sep 16, 2008 5:38 pm

Re: Granger and Newbold Monte Carlo Simulation

Postby EViews Gareth » Tue Apr 15, 2014 9:25 am



Return to “Programming”

Who is online

Users browsing this forum: No registered users and 2 guests