Select Git revision
identification_analysis.m
identification_analysis.m 13.51 KiB
function [ide_hess, ide_moments, ide_model, ide_lre, derivatives_info, info] = identification_analysis(params,indx,indexo,options_ident,data_info, prior_exist, name_tex, init)
% function [ide_hess, ide_moments, ide_model, ide_lre, derivatives_info, info] = identification_analysis(params,indx,indexo,options_ident,data_info, prior_exist, name_tex, init)
% given the parameter vector params, wraps all identification analyses
%
% INPUTS
% o params [array] parameter values for identification checks
% o indx [array] index of estimated parameters
% o indexo [array] index of estimated shocks
% o options_ident [structure] identification options
% o data_info [structure] data info for Kalmna Filter
% o prior_exist [integer]
% =1 when prior exists and indentification is checked only for estimated params and shocks
% =0 when prior is not defined and indentification is checked for all params and shocks
% o nem_tex [char] list of tex names
% o init [integer] flag for initialization of persistent vars
%
% OUTPUTS
% o ide_hess [structure] identification results using Asymptotic Hessian
% o ide_moments [structure] identification results using theoretical moments
% o ide_model [structure] identification results using reduced form solution
% o ide_lre [structure] identification results using LRE model
% o derivatives_info [structure] info about analytic derivs
% o info output from dynare resolve
%
% SPECIAL REQUIREMENTS
% None
% Copyright (C) 2008-2011 Dynare Team
%
% This file is part of Dynare.
%
% Dynare is free software: you can redistribute it and/or modify
% it under the terms of the GNU General Public License as published by
% the Free Software Foundation, either version 3 of the License, or
% (at your option) any later version.
%
% Dynare is distributed in the hope that it will be useful,
% but WITHOUT ANY WARRANTY; without even the implied warranty of
% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
% GNU General Public License for more details.
%
% You should have received a copy of the GNU General Public License
% along with Dynare. If not, see <http://www.gnu.org/licenses/>.
global oo_ M_ options_ bayestopt_ estim_params_
persistent indH indJJ indLRE
nparam=length(params);
np=length(indx);
offset=nparam-np;
set_all_parameters(params);
nlags = options_ident.ar;
useautocorr = options_ident.useautocorr;
advanced = options_ident.advanced;
replic = options_ident.replic;
periods = options_ident.periods;
max_dim_cova_group = options_ident.max_dim_cova_group;
normalize_jacobians = options_ident.normalize_jacobians;
[I,J]=find(M_.lead_lag_incidence');
ide_hess = struct();
ide_moments = struct();
ide_model = struct();
ide_lre = struct();
derivatives_info = struct();
[A,B,ys,info,M_,options_,oo_] = dynare_resolve(M_,options_,oo_);
if info(1)==0,
oo0=oo_;