set ystar %regstart() %regend() = xstates(t)(1)
set g_ystar = ystar - ystar{1}
linreg g_ystar
# constant
@RegHBreak
GAM2016 wrote:Hello,
Many thanks you for answer me and sorry for the wrong link.
I still have 3 problems to resolve and I will be grateful for your help!
1) On the new Laubach-Williams paper,I don’t understand how we get the Standard LW’s curve with rats program (page 28 ) http://www.frbsf.org/economic-research/files/wp2015-16.pdf
GAM2016 wrote:2) In your rats code, about the previous line on the code, I don’t understand how we get the dates 1973 and 1995
GAM2016 wrote:3) Finally, always in the code (about Phillips curve), I don’t understand how we get 0.42 and 0.58? Here is the few lines on the code from the whole code:
Phillips curve
*
linreg pceinflation 1961:1 *
# gap{1} pceinflation{1} pi3{2} pi5{5} pioilgap{1} piimpgap{0}
compute b3=%beta(1),b1=%beta(2),b2=%beta(3),b4=%beta(5),b5=%beta(6),sig2=sqrt(%seesq)
*
nonlin(parmset=peglam3) lamg=.042 lamz=sqrt(2)*.058
/* ----------------------------------------------------------------------
rst_data.g: Reads raw data from text file nr2_0902.q, and transforms
the data as described in the appendix to Laubach-Williams,
FEDS 2001-56. Last modified 09/03/02.
---------------------------------------------------------------------- */
output file = nr2_0902.dat reset;
screen off;
format /rd 9,4;
load daq[218,10] = nr2_0902.q;
daq[1:76,8] = daq[1:76,7]*daq[77,8]/daq[77,7];
mv = miss(0,0);
x = reshape(mv,218,7);
x[.,1:2] = ln(daq[.,2:3]);
x[.,3] = daq[1:45,4]|daq[46:218,5];
x[2:218,5] = 400*ln(daq[2:218,6]./daq[1:217,6]);
x[2:218,6] = 400*ln(daq[2:218,8]./daq[1:217,8]);
x[.,7] = 100*((1+daq[.,10]/36000)^365-1);
x[69:218,7] = daq[69:218,9];
yr = (x[10:218,3]+x[9:217,3]+x[8:216,3]+x[7:215,3])/4;
xr = x[6:218,3]~x[5:217,3]~x[4:216,3]~ones(213,1);
i = 1;
do while i <= 170;
beta = invpd(xr[i:i+39,.]'xr[i:i+39,.])*xr[i:i+39,.]'yr[i:i+39];
x[48+i,4] = xr[i+43,.]*beta;
i = i+1;
endo;
x;
end;
aubide wrote:What are the FRED codes of the data in nr2_0902.dat? I would like to update the model, but want to make sure I am not mixing and matching series. Thank you.
Return to Examples and Sample Code
Users browsing this forum: No registered users and 2 guests