Problem with running a SVAR code

For questions and discussion related to reading in and working with data.
indrani_5
Posts: 50
Joined: Tue Apr 12, 2016 10:09 pm

Problem with running a SVAR code

Unread post by indrani_5 »

Attached is a simple SVAR program/code. I dont understand why it keeps popping up

## SX7. ( Must Follow Immediately After Function Name
>>>>UMNS) 1960 2015 tr <<<<

when i run the code. Where am I going wrong?

Thanks
I
Attachments
andhra_final.xls
(30 KiB) Downloaded 689 times
andhra_fiscmult.RPF
(2.29 KiB) Downloaded 648 times
indrani_5
Posts: 50
Joined: Tue Apr 12, 2016 10:09 pm

Re: Problem with running a SVAR code

Unread post by indrani_5 »

Can someone please reply to my posted question. This is a bit urgent.
PeterF
Posts: 63
Joined: Thu Apr 12, 2012 2:03 pm

Re: Problem with running a SVAR code

Unread post by PeterF »

Hello,

downloading the program file and the Excel sheet with the data, I got the same error as you. After trying some other file formats and formatting also the date column, I finally got tested other variable names, and it worked. You have used reserved function names as series names. If you change them, for example from tr to a_tr, then it should work well.

Best regards
PeterF
indrani_5
Posts: 50
Joined: Tue Apr 12, 2016 10:09 pm

Re: Problem with running a SVAR code

Unread post by indrani_5 »

Thank you PeterF! It worked when I changed the names of the variables. Just a suggestion, I find that RATS is very sensitive to very trivial things when the objective of every researcher is to work on economic reasoning of the results. I think it might be possible for the programmers to reduce the sensitivity of RATS so that it becomes easy to use.
TomDoan
Posts: 7814
Joined: Wed Nov 01, 2006 4:36 pm

Re: Problem with running a SVAR code

Unread post by TomDoan »

indrani_5 wrote:Attached is a simple SVAR program/code. I dont understand why it keeps popping up

## SX7. ( Must Follow Immediately After Function Name
>>>>UMNS) 1960 2015 tr <<<<

when i run the code. Where am I going wrong?

Thanks
I
TR is an reserved name (for TRanspose). Since you have version 9, you have to rename it on the file. (RATS 10 allows you to rename variables as part of the DATA instruction so you could use something like XTR<<"TR" to rename the TR on the file to XTR in the workspace).

You also almost certainly are doing the dates wrong. 1960 means entry 1960, not year 1960. The latter is 1960:1. With TR renamed, you want:

OPEN DATA "E:\phd\research\RATS\andhra_final.xls"
CALENDER(A) 1960:1
DATA(FORMAT=XLS,ORG=COLUMNS) 1960:1 2015:1 xtr te gdp
Post Reply