@ This program reads and filters the citibase series @ library pgraph; #include c:\Mydoc\pigia\courses\econ984\hp.txt; @ execute procedure for hp filter @ nobs=136; @ number of observations @ nser=4; l=1600; @ smoothing parameter @ load matser[]=c:\mydoc\pigia\courses\econ984\series; matser2=reshape(matser,nobs,nser); matserf=hp(matser2,l); corr_mat = corrx(matserf); vcov=vcx(matserf); /*print "Correlation matrix "; print " Cons Output Invest Hours"; print corr_mat; stdev=vcov^(1/2); print "standard deviations "; print " Cons Output Invest Hours"; print stdev;*/ c_raw = matser2[.,1]; c_fil = matserf[.,1]; periods = seqa(1,1,136); title("c raw"); xy(periods,c_raw); title("c fil"); xy(periods,c_fil); stdevcy=sqrt(vcov[1,1])/sqrt(vcov[2,2]); stdeviy=sqrt(vcov[3,3])/sqrt(vcov[2,2]); stdevny=sqrt(vcov[4,4])/sqrt(vcov[2,2]); print "sd(c)/sd(y) sd(i)/sd(y) sd(n)/sd(y)"; print stdevcy; print stdeviy; print stdevny; print "corr c,i,n & y"; print corr_mat[1,2]; print corr_mat[2,2]; print corr_mat[3,2]; print corr_mat[4,2];