rtadf

For questions about EViews Add-ins available from the EViews Add-ins webpage. Note each add-in available on our webpage will have its own individual thread.

Moderators: EViews Gareth, EViews Moderator, EViews Esther

ioanniskork
Posts: 2
Joined: Wed Sep 03, 2014 4:24 am

Re: rtadf

Postby ioanniskork » Sat Sep 06, 2014 2:18 am

Dear Itamar,

Thank you for your reply. I am pretty sure that the "gsadf" contains the test-statistics (and the 1%,5% or 10% of the sorted test-statistics) are the critical values. Are these critical values of the BSADF? Then how can we implement the GSADF process? Which method should be used as a date-stamping strategy?

Could you please provide a brief explanation of each method?

Thank you in advance.

Regards,
Ioannis

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Sun Sep 07, 2014 4:54 am

Hi,

Forgive me if I wasn't clear. I'll try again:

- 'gsadf' is the test statistics sequence. This is what PSY call the BSADF sequence.
- 'gsadf_cv' is the corresponding critical values sequence of the BSADF at a chosen significance level (beta).
- The starting point of a bubble period is marked as the date at which 'gsadf' crosses 'gsadf_cv' from below and the endpoint is where 'gsadf' crosses 'gsadf_cv' from above.

BTW, there is a bug in the add-in - some error about %BETA_PC when running the GSADF test. I will fix it in the next update of the add-in. In the meanwhile, the output has all the info you need to perform the GSADF test.


Itamar

joburg
Posts: 5
Joined: Tue Sep 03, 2013 1:28 am

Re: rtadf

Postby joburg » Fri Sep 19, 2014 5:41 pm

Good day Itamar

Im currently working on a project where i have variables that i want to use in your RTADF group code loop.

Although i can read the coding a bit, i am still new to actually programming the functions in Eviews. Is it at all possible to have the group code run and have the critical values change in a kind of loop. So that in the end, if i have 3 variables on which i want to apply the model, i want to end up with 9 graphs, each of the variables using 90%, 95% and 99% critical values.

If it is unclear to what i am looking for, please let me know

If so, could you advise me perhaps on how this is done?

Regards,
J

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Sun Sep 21, 2014 7:41 am

Dear J,

I believe what your asking for can be achieved fairly easily. All you need to do is add your choice of a confidence level (beta) to the simulation command line. The default beta is set to 95%. If instead, for example, you wish to set beta to 90%l, just add "beta=0.90" to the simulation command line (see in boldface):

'generate critical values for the common sample length using the first series as input
smpl %sample
%i=g01.@seriesname(1)
{%i}.rtadf(const,model=!model,lag=!lag,win=!win,sim, rep=!rep, d=0, beta=0.90)
rtadf_spool.extract(tstat_{%i}) untitled01
close tstat_{%i}
for !i=1 to 3
stats(!i,2)=tstat_{%i}(11+!i,4)
next

The rest of the code need not change. You will, however, need to run this code 3 times for each beta in order to get 9 graphs. (Of course you can always optimize this code by running a loop over 'beta'. it's your call)

Hope this helps!

Itamat

joburg
Posts: 5
Joined: Tue Sep 03, 2013 1:28 am

Re: rtadf

Postby joburg » Mon Sep 22, 2014 6:15 am

Dear Itamat

Thank so much for your reply! Definitely what i was looking for. Ill run the coding now and maybe insert that loop at a later stage

Regards
J

juanpmosca
Posts: 2
Joined: Wed Oct 01, 2014 7:49 am

PRoblems with BETA_PC

Postby juanpmosca » Wed Oct 01, 2014 8:07 am

Hi Itamar,

I am an old user of Phillips, Shi and Yu methods, but i used them on MATLAB.
Your patch on eviews facilitates my work so much (thanks in advide), but i am having a problem with models 2 and 4. When i do the test by PROC-ADD INS or by the formula specified on your paper a problem called BETA_PC appears, it may be caused by a broken simulation. I followed your reccomendation suggested on a previous post but it does not get any better. What can i do?

Thank you Itamar.

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Thu Oct 02, 2014 1:46 am

Hi,

I fixed this problem in the new version of Rtadf (version 1.3). It should appear in EViews add-ins website within the next few days. If you wish, send me your email in a private message and I'll send you the installation file by mail.

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Sat Oct 04, 2014 4:16 am

A new version (1.3) of the Rtadf addin is now available at the EViews addin page. The update includes the following improvements:

- The output table and graph are now presented within the series object.
- Output objects now include only the following three: the sequence of test statistics, sequence of critical values and a vector which holds the simulated critical values. For example, if you use the SADF test you'll get 'sadf' ,'sadf_cv' and 'sadf_dist' respectively.
- An updated user guide
- Bug fixes (including the BETA_PC bug)

Itamar

juanpmosca
Posts: 2
Joined: Wed Oct 01, 2014 7:49 am

Re: rtadf

Postby juanpmosca » Mon Oct 06, 2014 8:03 am

Itamar,
I used the 3rd model for the stamping and it worked.

Thanks, your patch helped me a lot.

Juan Pablo

nishantvats12
Posts: 34
Joined: Wed Mar 19, 2014 9:28 pm
Location: India

Re: rtadf

Postby nishantvats12 » Mon Nov 10, 2014 7:56 am

I am using the monthly dividend yield data. I am successfully able to run the 1,2 and 3 model using the latest version of rtadf package with EViews 8.0.
However, when I run model 4 (GSADF) it is showing two issues:

1. Enormous amount of computation time (However it is ok!!) {It is not happening for other 3 models}
2. At the end it is showing an error "BETA_PC" not defined.
3. For all the models despite selecting AIC it is selecting the lag length based on SIC only.

PS: For lag length selection I used AIC with 3 lags.

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Wed Nov 12, 2014 5:37 am

Hi,

1. Yep, the GSADF test takes A LOT of time since it runs a lot of regressions. I am currently working on ways to parallelize the code with the help of a 3rd party software but it is in experimental stages. I'll post an update once it is ready.
2. You probably have an earlier version of the add-in. Download the latest from EViews' add-in webpage. The BETA_PC bug should be fixed. If not, let me know.
3. I tested it myself and I don't see any problems. Maybe in your specific case the results of both criteria coincide? Try using a larger number of maximum lags, say 8, and see if it is still the same.

ThomasFJ
Posts: 1
Joined: Fri May 15, 2015 2:25 am

Re: rtadf

Postby ThomasFJ » Fri May 15, 2015 3:34 am

Dear Itamar,

First of all, thank you for a great add-in. It has been of tremendous help for us.

I am using the latest version (1.4) and I still seem to run into the occasional beta_pc problem. However, I think I have come up with a possible solution.

In the rtadfsim program, the beta_pc scalar is created just before the pagecreate statement, whereas the cv table is created right after this. This results in the beta_pc scalar being created on the initial default page containing data and the cv table being created on the simulation page.

This creates a problem for the following piece of code (from the rtadf program) as eviews is trying to copy beta_pc from the simulation page to the default page. However, beta_pc does not exist on the simulation page. Often, the program will not result in an error, but keep on going. The results will be correct since beta_pc is already present on the default page, which is what we are trying to achieve. However, sometimes it will prompt an error since we are trying to copy something that does not exist.

Code: Select all

'import simulation results to default page
   pageselect simulation
   %simpagename = @pagename
   pageselect {%datapagename}
   copy {%simpagename}\cv cv
   copy {%simpagename}\beta_pc
   %beta_pc = @str(beta_pc)


Solution:
In the rtadfsim code, move the creation statement of the scalar beta_pc a couple of lines down, such that it is below the pagecreate statement. The scalar will now be created on the simulation page and can thus be copied from there. I have altered my code to the following:

Code: Select all

!d = @val(%d)
!eta = @val(%eta)
!theta = @val(%theta)
!beta = @val(%beta)

'create a new page
!totalobs = !runin+!T
pagecreate(page=simulation) u !totalobs

scalar beta_pc = @round(!beta*100)


Additionally, I have added a destination to the copy statement in the rtadf program. However, this seems to be redundant, so this change might not need to be made.

Code: Select all

'changed from this
copy {%simpagename}\beta_pc
'to this
copy {%simpagename}\beta_pc beta_pc


/Thomas

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Wed May 20, 2015 6:56 am

Dear Thomas,

Thanks for your kind words!
your suggestion seems to work well. I am currently working on an update for the 'rtadf' add-in and you've just saved me some work ;)
BTW, the new version will allow the user to run the simulations in parallel via MATLAB, an option that cuts simulation running time dramatically...
Hope to have it uploaded soon.

Best,
Itamar

tofan.anca
Posts: 1
Joined: Thu May 21, 2015 2:21 am

Re: rtadf

Postby tofan.anca » Thu May 21, 2015 2:49 am

Hello Itamar,

I am trying to use the Phillips, Shi and Yu methods for my bachelor degree thesis. I downloaded the eviews add ins from the EViews site, but when I run the test a problem called BETA_PC appears. I read here on the forum about this problem, but the RTADF add ins that I downloaded from the site is from 2013/08/28. I saw that you wrote on this forum that you uploaded a new version in March 2014 but I can't find it anywhere. I need some help, so can you tell me where else can I find the latest version of the RTADF add ins?

Best regards,
Anca.

Itamar
Posts: 25
Joined: Wed Mar 12, 2014 12:31 pm

Re: rtadf

Postby Itamar » Tue Jun 02, 2015 10:55 pm

Dear Anca,

Sorry for the late response. Please send me your email address in a private message so I am able to send you the latest version I have ready.

Best,
Itamar


Return to “Add-in Support”

Who is online

Users browsing this forum: No registered users and 16 guests