18.06.2013 Views

Measuring the Effects of a Shock to Monetary Policy - Humboldt ...

Measuring the Effects of a Shock to Monetary Policy - Humboldt ...

Measuring the Effects of a Shock to Monetary Policy - Humboldt ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Bayesian FAVARs with Agnostic Identification 103<br />

%%%%%%**********************************************************%%%%%<br />

%%%%%% DO_CALCULATION_GIBBS_SAMPLING_PARAM_PREC_OBS %%%%%<br />

%%%%%% %%%%%<br />

%%%%%% see Sequence Diagram Block B.3.3 %%%%%<br />

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%<br />

%%%%%% Inference on Observation Equation<br />

function [param_prec_obs] = DO_CALCULATION_GIBBS_SAMPLING_PARAM_PREC_OBS (input, bk_smoo<strong>the</strong>r);<br />

%function [param_prec_obs] = DO_CALCULATION_GIBBS_SAMPLING_PARAM_PREC_OBS (input, bk_smoo<strong>the</strong>r);<br />

global calculation;<br />

%%%%% set parameters<br />

XX = calculation.stateSpaceStructure.XX;<br />

K = input.specification.model.K;<br />

M = input.specification.dim.M;<br />

N = input.specification.dim.N;<br />

T = input.specification.dim.T;<br />

Xsi_S = bk_smoo<strong>the</strong>r.Xsi_S(:,1:K+M);<br />

% prior distributions for VAR part, need Lam and R<br />

s0 = 3;<br />

alpha = 0.001;<br />

M0 = eye(K+M); % Variance Parameter in prior on i-th coeff<br />

Param1 = inv( M0 + inv(Xsi_S’*Xsi_S) ) ;<br />

for i=1:N<br />

if i K<br />

%**********************%<br />

% b) draw Lam_ii %<br />

%**********************%<br />

% Given : Fac<strong>to</strong>rs,Data, and Previously generated R_ii

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!