Last active
December 24, 2015 09:59
-
-
Save stepan-a/6781075 to your computer and use it in GitHub Desktop.
A dynare script with dates to be converted in dynDate(s) objects. The conversion by convert_dates_in_mod_file.m (see https://gist.github.com/stepan-a/6780885) matlab's routine should produce something similar to what is shown in dynare_script_with_dates.mod-subs-dates (second file).
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Y, Z, X; | |
parameters a, b, c, d; | |
set_time(1990Q3); | |
disp('Current date is 1990Q3.') | |
rawdata = dynSeries('data.m'); | |
// Par un décret des puissances suprêmes, le poête apparait en 1990Q3 | |
% Par un décret des puissances suprêmes, le poête apparait en 1990Q3. | |
range = 1995Q3:2000Q2; | |
rawdata = rawdata(range).log(); | |
rawdata = rawdata{'Y','Z'}; | |
X = rawdata(range).X; | |
Y = rawdata(range).Y; | |
obs = rawdata(1990Q3); | |
data(file='../data/mydata.csv',first_obs=1990Q4,last_obs=2000Q3); | |
Q = Y - Y(-1) + X(1); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var Y, Z, X; | |
parameters a, b, c, d; | |
set_time(1990Q3); | |
disp('Current date is 1990Q3.') | |
rawdata = dynSeries('data.m'); | |
// Par un décret des puissances suprêmes, le poête apparait en 1990Q3 | |
range = dynDate('1995Q3'):dynDate('2000Q2'); | |
rawdata = rawdata(range).log(); | |
rawdata = rawdata{'Y','Z'}; | |
X = rawdata(range).X; | |
Y = rawdata(range).Y; | |
obs = rawdata(dynDate('1990Q3')); | |
data(file='../data/mydata.csv',first_obs=1990Q4,last_obs=2000Q3); | |
Q = Y - Y(-1) + X(1); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment