AIM tests auxiliary files

git-svn-id: https://www.dynare.org/svn/dynare/trunk@2520 ac1d8469-bf42-47a9-8791-bf33cf982152
time-shift
george 2009-03-25 16:46:11 +00:00
parent e1c13c256a
commit 6e633aad31
3 changed files with 375 additions and 0 deletions

100
tests/AIM/data_ca1.m Normal file
View File

@ -0,0 +1,100 @@
data = [0.928467646476 11.8716889412 20 0.418037507392 0.227382377518 ...
-0.705994063083 11.7522582094 21.25 1.09254424511 -1.29488274994 ...
-0.511895351926 9.68144025625 17.25 -1.66150408407 0.331508393098 ...
-0.990955971267 10.0890781236 17 1.43016275252 -2.43589670141 ...
-0.981233061806 12.1094840679 18.25 2.91293288733 -0.790246576864 ...
-0.882182844512 8.54559460406 15 0.419579139481 0.358729719566 ...
-0.930893002836 6.19238374422 12.5 -1.48847457959 0.739779938797 ...
1.53158206947 2.76544271886 11.5 -0.336216769682 0.455559918769 ...
2.2659052834 5.47418162513 11 0.306436789767 -0.0707985731221 ...
1.05419803797 6.35698426189 11 0.140700250477 0.620401487202 ...
1.20161076793 3.4253301593 11 0.461296492351 0.14354323987 ...
1.73934077971 4.70926070322 11.5 1.35798282982 0.38564694435 ...
1.71735262584 3.54232079749 12.5 2.9097529155 -0.804308583301 ...
0.426343657844 3.32719108897 13 1.64214862652 -1.18214664701 ...
1.67751812324 2.93444727338 11.25 0.344434910651 -1.6529373719 ...
1.37013301099 4.72303361923 11.75 2.61511526582 0.327684243041 ...
0.281231073781 4.4893853071 10.5 1.17043449257 1.12855106649 ...
1.53638992834 3.7325309699 10.25 -0.683947046728 0.11943538737 ...
1.68081431462 3.34729969129 10 1.41159342106 -1.59065680853 ...
-0.343321601133 5.05563513564 12 1.75117366498 -2.40127764642 ...
0.873415608666 3.2779996255 10.25 -1.39895866711 0.0971444398216 ...
0.26399696544 4.78229419828 9.75 0.0914692438124 0.299310457612 ...
-0.562233624818 3.88598638237 9.75 -0.0505384765105 0.332826708151 ...
2.15161914936 3.84859710132 8.75 -3.44811080489 0.789138678784 ...
1.2345093726 5.62225030942 9.5 -0.366945407434 2.32974981198 ...
1.62554967459 4.24667132831 10 -0.800958371402 0.0293183770935 ...
1.33035402527 2.75248979249 9.75 -0.855723113225 0.852493939813 ...
1.52078814077 3.53415985826 9.75 -3.37963469203 -1.05133958119 ...
1.16704983697 4.92754079464 10.75 -3.0142303324 0.459907431978 ...
0.277213572101 4.55532133037 11.75 -0.851995599415 2.03242034852 ...
0.842215068977 3.11164509647 12.25 -1.08290421696 0.014323281961 ...
1.05325028606 4.92882647578 13.5 -1.1953883867 0.706764750654 ...
0.453051253568 6.82998950103 13.5 0.111803656462 0.088462593153 ...
0.199885995525 5.82643354662 13.5 -0.920501518421 -0.26504958666 ...
0.137907999624 2.66076369132 13.5 -1.17122929812 -0.995642430514 ...
0.721949686709 5.70497876823 14.25 1.19378169018 -1.10644839651 ...
-0.418465249225 3.75861110232 14.75 -1.03131674824 0.188507675831 ...
-0.644028342116 4.15104788154 13.75 -1.48911756546 0.204560913792 ...
-0.848213852668 5.65580324027 12.75 0.677011703877 -0.849628054542 ...
-1.51954076928 11.4866911266 11.25 -0.446024680774 -0.456342350765 ...
0.265275055215 2.85472749592 9.75 -0.598778202436 -0.907311640831 ...
0.356162529063 2.29614015658 9.5 -0.46820788432 -1.22130883441 ...
0.368308864363 -0.539083504685 8 -0.781333991956 0.374007246518 ...
-0.145751412732 1.61507621789 8.25 3.68291932628 1.32438399845 ...
0.285457283664 2.14334055993 7 1.42819405379 -0.00818660844123 ...
0.372390129412 1.60000213334 6.25 0.626106424052 -0.10136772765 ...
0.382720203063 1.72614243263 7.25 4.89631941021 -1.10060711916 ...
0.737957515573 2.90430582851 6 -0.0422721010314 0.4178952497 ...
0.649532581668 0.657135682543 6 0.692066153971 0.422299120276 ...
0.627159201987 1.70352689913 5.75 2.62066711305 -1.29237304034 ...
0.905441299817 1.95663197267 5.5 1.5949697565 -0.27115830703 ...
1.49322577898 -2.08741765309 6.25 1.23027694802 0.418336889527 ...
1.48750731567 -1.57274121871 8 3.01660550994 -0.893958254365 ...
1.39783858087 2.22623066426 7 -0.80842319214 1.47625453886 ...
0.89274836317 1.30378081742 8 -0.249485058661 0.159871204185 ...
0.920652246088 4.1437741965 9.75 2.8204453623 0.178149239655 ...
-0.00264276644799 3.07989972052 8.75 -2.56342461535 2.105998353 ...
0.0198190461681 0.766283759256 8 -1.15838865989 1.56888883418 ...
0.440050515311 0.127570085801 7.5 0.0400753569995 0.028914333532 ...
0.129536637901 1.78174141526 6.75 0.959943962785 0.307781224401 ...
0.398549827172 3.03606770667 6.5 -0.340209794742 0.100979469478 ...
1.17174775425 0.629625188037 5.75 0.403003686814 0.902394579377 ...
0.991163981251 2.50862910684 4.75 -1.44963996982 1.16150986945 ...
0.967603566096 2.12003739013 4.75 0.610846030775 -0.889994896068 ...
1.14689383604 1.24185011459 4.75 2.01098091308 -1.73846431001 ...
1.32593824054 0.990713820685 4.75 -0.0955142989332 -0.0369257308362 ...
0.861135002644 -0.24744943605 6 1.72793107135 -0.691506789639 ...
1.26870850151 2.09844764887 6.5 1.50720217572 -1.31399187077 ...
0.260364987715 1.10650139716 6.5 1.13659047496 0.0720441664643 ...
1.09731242214 0.490796381346 7.25 4.59123894147 -2.14073070763 ...
1.63792841781 0.612652594286 6.75 1.79604605035 -0.644363995357 ...
1.48465576034 0.978295808687 6.75 -2.00753620902 1.39437534964 ...
1.0987608663 4.25212569087 6.25 -2.58901196498 2.56054320803 ...
1.42592178132 2.76984518311 6.25 0.888195752358 1.03114549274 ...
1.52958239462 1.31795955491 6.5 -0.902907564082 -0.0952198893776 ...
1.0170168994 2.14733589918 7 -1.3054866978 2.68803738466 ...
0.723253652257 3.43552889347 7.5 1.8213700853 0.592593586195 ...
1.24720806008 3.87383806577 7.5 0.0522300654168 0.988871238698 ...
0.482531471239 2.67793287032 7.5 2.9693944293 -0.108591166081 ...
0.154056100439 0.927269031704 6.75 0.119222057561 3.30489209451 ...
0.0694865769274 6.65916526788 6.25 0.889014476084 -2.83976849035 ...
-0.121267434867 0.341442615696 5.25 0.323053239216 -3.49289229012 ...
0.726473690375 -3.5423730964 4 2.19149290449 -3.20855054004 ...
1.39271709108 2.63121085718 3.75 0.88406577736 0.75622580197 ...
1.07502077727 5.88578836799 4.25 -2.55088273352 2.89018116374 ...
0.759049251607 4.24703604223 4.5 0.575687665685 -0.388292506167 ...
];
data = reshape(data,5,86)';
y_obs = data(:,1);
pie_obs = data(:,2);
R_obs = data(:,3);
de = data(:,4);
dq = data(:,5);
%Country: Canada
%Sample Range: 1981:2 to 2002:3
%Observations: 86
%Variables: Real GDP Growth [%], Inflation [annualized %], Nom Rate [%],
% Exchange Rate Change [%], Terms of Trade Change [%]

View File

@ -0,0 +1,65 @@
% computes the steady state of fs2000 analyticaly
% largely inspired by the program of F. Schorfheide
function [ys,check] = fs2000k_steadystate(ys,exe)
global M_
alp = M_.params(1);
bet = M_.params(2);
gam = M_.params(3);
mst = M_.params(4);
rho = M_.params(5);
psi = M_.params(6);
del = M_.params(7);
check = 0;
dA = exp(gam);
gst = 1/dA;
m = mst;
khst = ( (1-gst*bet*(1-del)) / (alp*gst^alp*bet) )^(1/(alp-1));
xist = ( ((khst*gst)^alp - (1-gst*(1-del))*khst)/mst )^(-1);
nust = psi*mst^2/( (1-alp)*(1-psi)*bet*gst^alp*khst^alp );
n = xist/(nust+xist);
P = xist + nust;
k = khst*n;
l = psi*mst*n/( (1-psi)*(1-n) );
c = mst/P;
d = l - mst + 1;
y = k^alp*n^(1-alp)*gst^alp;
R = mst/bet;
W = l/n;
ist = y-c;
q = 1 - d;
e = 1;
gp_obs = m/dA;
gy_obs = dA;
P_obs = 1;
Y_obs = 1;
P2=P;
c2=c;
ys =[
m
P
c
e
W
R
k
d
n
l
gy_obs
gp_obs
Y_obs
P_obs
y
dA
P2
c2 ];

210
tests/AIM/fsdat.m Normal file
View File

@ -0,0 +1,210 @@
data_q = [
18.02 1474.5 150.2
17.94 1538.2 150.9
18.01 1584.5 151.4
18.42 1644.1 152
18.73 1678.6 152.7
19.46 1693.1 153.3
19.55 1724 153.9
19.56 1758.2 154.7
19.79 1760.6 155.4
19.77 1779.2 156
19.82 1778.8 156.6
20.03 1790.9 157.3
20.12 1846 158
20.1 1882.6 158.6
20.14 1897.3 159.2
20.22 1887.4 160
20.27 1858.2 160.7
20.34 1849.9 161.4
20.39 1848.5 162
20.42 1868.9 162.8
20.47 1905.6 163.6
20.56 1959.6 164.3
20.62 1994.4 164.9
20.78 2020.1 165.7
21 2030.5 166.5
21.2 2023.6 167.2
21.33 2037.7 167.9
21.62 2033.4 168.7
21.71 2066.2 169.5
22.01 2077.5 170.2
22.15 2071.9 170.9
22.27 2094 171.7
22.29 2070.8 172.5
22.56 2012.6 173.1
22.64 2024.7 173.8
22.77 2072.3 174.5
22.88 2120.6 175.3
22.92 2165 176.045
22.91 2223.3 176.727
22.94 2221.4 177.481
23.03 2230.95 178.268
23.13 2279.22 179.694
23.22 2265.48 180.335
23.32 2268.29 181.094
23.4 2238.57 181.915
23.45 2251.68 182.634
23.51 2292.02 183.337
23.56 2332.61 184.103
23.63 2381.01 184.894
23.75 2422.59 185.553
23.81 2448.01 186.203
23.87 2471.86 186.926
23.94 2476.67 187.68
24 2508.7 188.299
24.07 2538.05 188.906
24.12 2586.26 189.631
24.29 2604.62 190.362
24.35 2666.69 190.954
24.41 2697.54 191.56
24.52 2729.63 192.256
24.64 2739.75 192.938
24.77 2808.88 193.467
24.88 2846.34 193.994
25.01 2898.79 194.647
25.17 2970.48 195.279
25.32 3042.35 195.763
25.53 3055.53 196.277
25.79 3076.51 196.877
26.02 3102.36 197.481
26.14 3127.15 197.967
26.31 3129.53 198.455
26.6 3154.19 199.012
26.9 3177.98 199.572
27.21 3236.18 199.995
27.49 3292.07 200.452
27.75 3316.11 200.997
28.12 3331.22 201.538
28.39 3381.86 201.955
28.73 3390.23 202.419
29.14 3409.65 202.986
29.51 3392.6 203.584
29.94 3386.49 204.086
30.36 3391.61 204.721
30.61 3422.95 205.419
31.02 3389.36 206.13
31.5 3481.4 206.763
31.93 3500.95 207.362
32.27 3523.8 208
32.54 3533.79 208.642
33.02 3604.73 209.142
33.2 3687.9 209.637
33.49 3726.18 210.181
33.95 3790.44 210.737
34.36 3892.22 211.192
34.94 3919.01 211.663
35.61 3907.08 212.191
36.29 3947.11 212.708
37.01 3908.15 213.144
37.79 3922.57 213.602
38.96 3879.98 214.147
40.13 3854.13 214.7
41.05 3800.93 215.135
41.66 3835.21 215.652
42.41 3907.02 216.289
43.19 3952.48 216.848
43.69 4044.59 217.314
44.15 4072.19 217.776
44.77 4088.49 218.338
45.57 4126.39 218.917
46.32 4176.28 219.427
47.07 4260.08 219.956
47.66 4329.46 220.573
48.63 4328.33 221.201
49.42 4345.51 221.719
50.41 4510.73 222.281
51.27 4552.14 222.933
52.35 4603.65 223.583
53.51 4605.65 224.152
54.65 4615.64 224.737
55.82 4644.93 225.418
56.92 4656.23 226.117
58.18 4678.96 226.754
59.55 4566.62 227.389
61.01 4562.25 228.07
62.59 4651.86 228.689
64.15 4739.16 229.155
65.37 4696.82 229.674
66.65 4753.02 230.301
67.87 4693.76 230.903
68.86 4615.89 231.395
69.72 4634.88 231.906
70.66 4612.08 232.498
71.44 4618.26 233.074
72.08 4662.97 233.546
72.83 4763.57 234.028
73.48 4849 234.603
74.19 4939.23 235.153
75.02 5053.56 235.605
75.58 5132.87 236.082
76.25 5170.34 236.657
76.81 5203.68 237.232
77.63 5257.26 237.673
78.25 5283.73 238.176
78.76 5359.6 238.789
79.45 5393.57 239.387
79.81 5460.83 239.861
80.22 5466.95 240.368
80.84 5496.29 240.962
81.45 5526.77 241.539
82.09 5561.8 242.009
82.68 5618 242.52
83.33 5667.39 243.12
84.09 5750.57 243.721
84.67 5785.29 244.208
85.56 5844.05 244.716
86.66 5878.7 245.354
87.44 5952.83 245.966
88.45 6010.96 246.46
89.39 6055.61 247.017
90.13 6087.96 247.698
90.88 6093.51 248.374
92 6152.59 248.928
93.18 6171.57 249.564
94.14 6142.1 250.299
95.11 6078.96 251.031
96.27 6047.49 251.65
97 6074.66 252.295
97.7 6090.14 253.033
98.31 6105.25 253.743
99.13 6175.69 254.338
99.79 6214.22 255.032
100.17 6260.74 255.815
100.88 6327.12 256.543
101.84 6327.93 257.151
102.35 6359.9 257.785
102.83 6393.5 258.516
103.51 6476.86 259.191
104.13 6524.5 259.738
104.71 6600.31 260.351
105.39 6629.47 261.04
106.09 6688.61 261.692
106.75 6717.46 262.236
107.24 6724.2 262.847
107.75 6779.53 263.527
108.29 6825.8 264.169
108.91 6882 264.681
109.24 6983.91 265.258
109.74 7020 265.887
110.23 7093.12 266.491
111 7166.68 266.987
111.43 7236.5 267.545
111.76 7311.24 268.171
112.08 7364.63 268.815
];
%GDPD GDPQ GPOP
series = zeros(193,2);
series(:,2) = data_q(:,1);
series(:,1) = 1000*data_q(:,2)./data_q(:,3);
Y_obs = series(:,1);
P_obs = series(:,2);
series = series(2:193,:)./series(1:192,:);
gy_obs = series(:,1);
gp_obs = series(:,2);
ti = [1950:0.25:1997.75];