Home > matlab > dynare_identification.m

dynare_identification

PURPOSE ^

function [pdraws, TAU, GAM, LRE, gp, H, JJ] = dynare_identification(options_ident, pdraws0)

SYNOPSIS ^

function [pdraws, TAU, GAM, LRE, gp, H, JJ] = dynare_identification(options_ident, pdraws0)

DESCRIPTION ^

function [pdraws, TAU, GAM, LRE, gp, H, JJ] = dynare_identification(options_ident, pdraws0)

 INPUTS
    o options_ident    [structure] identification options
    o pdraws0          [matrix] optional: matrix of MC sample of model params. 
    
 OUTPUTS
    o pdraws           [matrix] matrix of MC sample of model params used
    o TAU,             [matrix] MC sample of entries in the model solution (stacked vertically)
    o GAM,             [matrix] MC sample of entries in the moments (stacked vertically)
    o LRE,             [matrix] MC sample of entries in LRE model (stacked vertically)
    o gp,              [matrix] derivatives of the Jacobian (LRE model)
    o H,               [matrix] derivatives of the model solution
    o JJ               [matrix] derivatives of the  moments
    
 SPECIAL REQUIREMENTS
    None

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function [pdraws, TAU, GAM, LRE, gp, H, JJ] = dynare_identification(options_ident, pdraws0)
0002 %function [pdraws, TAU, GAM, LRE, gp, H, JJ] = dynare_identification(options_ident, pdraws0)
0003 %
0004 % INPUTS
0005 %    o options_ident    [structure] identification options
0006 %    o pdraws0          [matrix] optional: matrix of MC sample of model params.
0007 %
0008 % OUTPUTS
0009 %    o pdraws           [matrix] matrix of MC sample of model params used
0010 %    o TAU,             [matrix] MC sample of entries in the model solution (stacked vertically)
0011 %    o GAM,             [matrix] MC sample of entries in the moments (stacked vertically)
0012 %    o LRE,             [matrix] MC sample of entries in LRE model (stacked vertically)
0013 %    o gp,              [matrix] derivatives of the Jacobian (LRE model)
0014 %    o H,               [matrix] derivatives of the model solution
0015 %    o JJ               [matrix] derivatives of the  moments
0016 %
0017 % SPECIAL REQUIREMENTS
0018 %    None
0019 
0020 % main
0021 %
0022 % Copyright (C) 2010-2011 Dynare Team
0023 %
0024 % This file is part of Dynare.
0025 %
0026 % Dynare is free software: you can redistribute it and/or modify
0027 % it under the terms of the GNU General Public License as published by
0028 % the Free Software Foundation, either version 3 of the License, or
0029 % (at your option) any later version.
0030 %
0031 % Dynare is distributed in the hope that it will be useful,
0032 % but WITHOUT ANY WARRANTY; without even the implied warranty of
0033 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0034 % GNU General Public License for more details.
0035 %
0036 % You should have received a copy of the GNU General Public License
0037 % along with Dynare.  If not, see <http://www.gnu.org/licenses/>.
0038 
0039 global M_ options_ oo_ bayestopt_ estim_params_
0040 
0041 if exist('OCTAVE_VERSION')
0042     warning('off'),
0043 else
0044     warning off,
0045 end
0046 
0047 fname_ = M_.fname;
0048 if ~isfield(M_,'dname'),
0049     M_.dname = M_.fname;
0050 end
0051 options_ident = set_default_option(options_ident,'gsa_sample_file',0);
0052 options_ident = set_default_option(options_ident,'parameter_set','prior_mean');
0053 options_ident = set_default_option(options_ident,'load_ident_files',0);
0054 options_ident = set_default_option(options_ident,'useautocorr',0);
0055 options_ident = set_default_option(options_ident,'ar',1);
0056 options_ident = set_default_option(options_ident,'prior_mc',1);
0057 options_ident = set_default_option(options_ident,'prior_range',0);
0058 options_ident = set_default_option(options_ident,'periods',300);
0059 options_ident = set_default_option(options_ident,'replic',100);
0060 options_ident = set_default_option(options_ident,'advanced',0);
0061 options_ident = set_default_option(options_ident,'normalize_jacobians',1);
0062 options_ident = set_default_option(options_ident,'lik_init',1);
0063 if options_ident.gsa_sample_file,
0064     GSAFolder = checkpath('gsa',M_.dname);
0065     if options_ident.gsa_sample_file==1,
0066         load([GSAFolder,filesep,fname_,'_prior'],'lpmat','lpmat0','istable');
0067     elseif options_ident.gsa_sample_file==2,
0068         load([GSAFolder,filesep,fname_,'_mc'],'lpmat','lpmat0','istable');
0069     else
0070         load([GSAFolder,filesep,options_ident.gsa_sample_file],'lpmat','lpmat0','istable');
0071     end
0072     if isempty(istable),
0073         istable=1:size(lpmat,1);
0074     end
0075     if ~isempty(lpmat0),
0076         lpmatx=lpmat0(istable,:);
0077     else
0078         lpmatx=[];
0079     end
0080     pdraws0 = [lpmatx lpmat(istable,:)];
0081     clear lpmat lpmat0 istable;
0082 elseif nargin==1,
0083     pdraws0=[];
0084 end
0085 external_sample=0;
0086 if nargin==2 || ~isempty(pdraws0),
0087     options_ident.prior_mc=size(pdraws0,1);
0088     options_ident.load_ident_files = 0;
0089     external_sample=1;
0090 end
0091 if isempty(estim_params_),
0092     options_ident.prior_mc=1;
0093     options_ident.prior_range=0;
0094     prior_exist=0;
0095 else
0096     prior_exist=1;
0097     parameters = options_ident.parameter_set;
0098 end
0099 
0100 % options_ident.load_ident_files=1;
0101 iload = options_ident.load_ident_files;
0102 %options_ident.advanced=1;
0103 advanced = options_ident.advanced;
0104 nlags = options_ident.ar;
0105 periods = options_ident.periods;
0106 replic = options_ident.replic;
0107 useautocorr = options_ident.useautocorr;
0108 options_.order=1;
0109 options_.ar=nlags;
0110 options_.prior_mc = options_ident.prior_mc;
0111 options_.options_ident = options_ident;
0112 options_.Schur_vec_tol = 1.e-8;
0113 options_.nomoments=0;
0114 options_.analytic_derivation=1;
0115 
0116 options_ = set_default_option(options_,'datafile',[]);
0117 options_.mode_compute = 0;
0118 options_.plot_priors = 0;
0119 [dataset_,xparam1, M_, options_, oo_, estim_params_,bayestopt_]=dynare_estimation_init(M_.endo_names,fname_,1, M_, options_, oo_, estim_params_, bayestopt_);
0120 if isempty(dataset_),
0121     dataset_.info.ntobs = periods;
0122     dataset_.info.nvobs = rows(options_.varobs);
0123     dataset_.info.varobs = options_.varobs;
0124     dataset_.rawdata = [];
0125     dataset_.missing.state = 0;
0126     dataset_.missing.aindex = [];
0127     dataset_.missing.vindex = [];
0128     dataset_.missing.number_of_observations = [];
0129     dataset_.missing.no_more_missing_observations = [];
0130     dataset_.descriptive.mean = [];
0131     dataset_.data = [];
0132 
0133 %     data_info.gend = periods;
0134 %     data_info.data = [];
0135 %     data_info.data_index = [];
0136 %     data_info.number_of_observations = periods*size(options_.varobs,1);
0137 %     data_info.no_more_missing_observations = 0;
0138 %     data_info.missing_value = 0;
0139 end
0140 
0141 % results = prior_sampler(0,M_,bayestopt_,options_,oo_);
0142 
0143 if prior_exist
0144     if (~isnan(bayestopt_.pshape))
0145         if options_ident.prior_range
0146             prior_draw(1,1);
0147         else
0148             prior_draw(1);
0149         end
0150     else
0151         options_ident.prior_mc=1;
0152     end
0153 end
0154 
0155 SampleSize = options_ident.prior_mc;
0156 
0157 if ~(exist('sylvester3','file')==2),
0158 
0159     dynareroot = strrep(which('dynare'),'dynare.m','');
0160     addpath([dynareroot 'gensylv'])
0161 end
0162 
0163 IdentifDirectoryName = CheckPath('identification',M_.dname);
0164 if prior_exist,
0165 
0166     indx = [];
0167     if ~isempty(estim_params_.param_vals),
0168         indx = estim_params_.param_vals(:,1);
0169     end
0170     indexo=[];
0171     if ~isempty(estim_params_.var_exo)
0172         indexo = estim_params_.var_exo(:,1);
0173     end
0174 
0175     nparam = length(bayestopt_.name);
0176     np = estim_params_.np;
0177     name = bayestopt_.name;
0178     name_tex = char(M_.exo_names_tex(indexo,:),M_.param_names_tex(indx,:));
0179 
0180     offset = estim_params_.nvx;
0181     offset = offset + estim_params_.nvn;
0182     offset = offset + estim_params_.ncx;
0183     offset = offset + estim_params_.ncn;
0184 else
0185     indx = [1:M_.param_nbr];
0186     indexo = [1:M_.exo_nbr];
0187     offset = M_.exo_nbr;
0188     np = M_.param_nbr;
0189     nparam = np+offset;
0190     name = [cellstr(M_.exo_names); cellstr(M_.param_names)];
0191     name_tex = [cellstr(M_.exo_names_tex); cellstr(M_.param_names_tex)];
0192 end
0193 
0194 options_ident = set_default_option(options_ident,'max_dim_cova_group',min([2,nparam-1]));
0195 options_ident.max_dim_cova_group = min([options_ident.max_dim_cova_group,nparam-1]);
0196 
0197 
0198 MaxNumberOfBytes=options_.MaxNumberOfBytes;
0199 store_options_ident = options_ident;
0200 disp(' ')
0201 disp(['==== Identification analysis ====' ]),
0202 disp(' ')
0203 
0204 if iload <=0,
0205     
0206     [I,J]=find(M_.lead_lag_incidence');
0207     if prior_exist,
0208 %         if exist([fname_,'_mean.mat'],'file'),
0209 % %             disp('Testing posterior mean')
0210 %             load([fname_,'_mean'],'xparam1')
0211 %             pmean = xparam1';
0212 %             clear xparam1
0213 %         end
0214 %         if exist([fname_,'_mode.mat'],'file'),
0215 % %             disp('Testing posterior mode')
0216 %             load([fname_,'_mode'],'xparam1')
0217 %             pmode = xparam1';
0218 %             clear xparam1
0219 %         end
0220         params = set_prior(estim_params_,M_,options_)';
0221         if isnan(bayestopt_.pshape)
0222         parameters = 'ML_Starting_value';
0223         disp('Testing ML Starting value')
0224         else
0225         switch parameters
0226             case 'posterior_mode'
0227                 disp('Testing posterior mode')
0228                 params(1,:) = get_posterior_parameters('mode');
0229             case 'posterior_mean'
0230                 disp('Testing posterior mean')
0231                 params(1,:) = get_posterior_parameters('mean');
0232             case 'posterior_median'
0233                 disp('Testing posterior median')
0234                 params(1,:) = get_posterior_parameters('median');
0235             case 'prior_mode'
0236                 disp('Testing prior mode')
0237                 params(1,:) = bayestopt_.p5(:);
0238             case 'prior_mean'
0239                 disp('Testing prior mean')
0240                 params(1,:) = bayestopt_.p1;
0241             otherwise
0242                 disp('The option parameter_set has to be equal to:')
0243                 disp('                   ''posterior_mode'', ')
0244                 disp('                   ''posterior_mean'', ')
0245                 disp('                   ''posterior_median'', ')
0246                 disp('                   ''prior_mode'' or')
0247                 disp('                   ''prior_mean''.')
0248                 error;
0249         end
0250         end
0251     else
0252         params = [sqrt(diag(M_.Sigma_e))', M_.params'];
0253         parameters = 'Current_params';
0254         disp('Testing current parameter values')
0255     end
0256     [idehess_point, idemoments_point, idemodel_point, idelre_point, derivatives_info_point] = ...
0257         identification_analysis(params,indx,indexo,options_ident,dataset_, prior_exist, name_tex,1);
0258     idehess_point.params=params;
0259 %     siH = idemodel_point.siH;
0260 %     siJ = idemoments_point.siJ;
0261 %     siLRE = idelre_point.siLRE;
0262 %     normH = max(abs(siH)')';
0263 %     normJ = max(abs(siJ)')';
0264 %     normLRE = max(abs(siLRE)')';
0265     save([IdentifDirectoryName '/' M_.fname '_identif.mat'], 'idehess_point', 'idemoments_point','idemodel_point', 'idelre_point','store_options_ident')
0266     disp_identification(params, idemodel_point, idemoments_point, name);
0267     plot_identification(params,idemoments_point,idehess_point,idemodel_point,idelre_point,advanced,parameters,name,IdentifDirectoryName);
0268 
0269     if SampleSize > 1,
0270         disp(' ')
0271         disp('Monte Carlo Testing')
0272         h = dyn_waitbar(0,'Monte Carlo identification checks ...');
0273         iteration = 0;
0274         loop_indx = 0;
0275         file_index = 0;
0276         run_index = 0;
0277         options_MC=options_ident;
0278         options_MC.advanced=0;
0279     else
0280         iteration = 1;
0281         pdraws = [];
0282     end
0283     while iteration < SampleSize,
0284         loop_indx = loop_indx+1;
0285         if external_sample,
0286             params = pdraws0(iteration+1,:);
0287         else
0288             params = prior_draw();
0289         end
0290         [dum1, ideJ, ideH, ideGP, dum2 , info] = ...
0291             identification_analysis(params,indx,indexo,options_MC,dataset_, prior_exist, name_tex,0);
0292         if iteration==0,
0293             MAX_tau   = min(SampleSize,ceil(MaxNumberOfBytes/(size(ideH.siH,1)*nparam)/8));
0294             stoH = zeros([size(ideH.siH,1),nparam,MAX_tau]);
0295             stoJJ = zeros([size(ideJ.siJ,1),nparam,MAX_tau]);
0296             stoLRE = zeros([size(ideGP.siLRE,1),np,MAX_tau]);
0297             TAU = zeros(size(ideH.siH,1),SampleSize);
0298             GAM = zeros(size(ideJ.siJ,1),SampleSize);
0299             LRE = zeros(size(ideGP.siLRE,1),SampleSize);
0300             pdraws = zeros(SampleSize,nparam);
0301             idemoments.indJJ = ideJ.indJJ;
0302             idemodel.indH = ideH.indH;
0303             idelre.indLRE = ideGP.indLRE;
0304             idemoments.ind0 = zeros(SampleSize,nparam);
0305             idemodel.ind0 = zeros(SampleSize,nparam);
0306             idelre.ind0 = zeros(SampleSize,np);
0307             idemoments.jweak = zeros(SampleSize,nparam);
0308             idemodel.jweak = zeros(SampleSize,nparam);
0309             idelre.jweak = zeros(SampleSize,np);
0310             idemoments.jweak_pair = zeros(SampleSize,nparam*(nparam+1)/2);
0311             idemodel.jweak_pair = zeros(SampleSize,nparam*(nparam+1)/2);
0312             idelre.jweak_pair = zeros(SampleSize,np*(np+1)/2);
0313             idemoments.cond = zeros(SampleSize,1);
0314             idemodel.cond = zeros(SampleSize,1);
0315             idelre.cond = zeros(SampleSize,1);
0316             idemoments.Mco = zeros(SampleSize,nparam);
0317             idemodel.Mco = zeros(SampleSize,nparam);
0318             idelre.Mco = zeros(SampleSize,np);
0319             idemoments.S = zeros(SampleSize,min(8,nparam));
0320             idemoments.V = zeros(SampleSize,nparam,min(8,nparam));
0321             delete([IdentifDirectoryName '/' M_.fname '_identif_*.mat'])
0322         end
0323         if info(1)==0,
0324             iteration = iteration + 1;
0325             run_index = run_index + 1;
0326             TAU(:,iteration)=ideH.TAU;
0327             LRE(:,iteration)=ideGP.LRE;
0328             GAM(:,iteration)=ideJ.GAM;
0329             idemoments.cond(iteration,1)=ideJ.cond;
0330             idemodel.cond(iteration,1)=ideH.cond;
0331             idelre.cond(iteration,1)=ideGP.cond;
0332             idemoments.ino(iteration,1)=ideJ.ino;
0333             idemodel.ino(iteration,1)=ideH.ino;
0334             idelre.ino(iteration,1)=ideGP.ino;
0335             idemoments.ind0(iteration,:)=ideJ.ind0;
0336             idemodel.ind0(iteration,:)=ideH.ind0;
0337             idelre.ind0(iteration,:)=ideGP.ind0;
0338             idemoments.jweak(iteration,:)=ideJ.jweak;
0339             idemodel.jweak(iteration,:)=ideH.jweak;
0340             idelre.jweak(iteration,:)=ideGP.jweak;
0341             idemoments.jweak_pair(iteration,:)=ideJ.jweak_pair;
0342             idemodel.jweak_pair(iteration,:)=ideH.jweak_pair;
0343             idelre.jweak_pair(iteration,:)=ideGP.jweak_pair;
0344             idemoments.Mco(iteration,:)=ideJ.Mco;
0345             idemodel.Mco(iteration,:)=ideH.Mco;
0346             idelre.Mco(iteration,:)=ideGP.Mco;
0347             idemoments.S(iteration,:)=ideJ.S;
0348             idemoments.V(iteration,:,:)=ideJ.V;
0349             stoLRE(:,:,run_index) = ideGP.siLRE;
0350             stoH(:,:,run_index) = ideH.siH;
0351             stoJJ(:,:,run_index) = ideJ.siJ;
0352             pdraws(iteration,:) = params;
0353             if run_index==MAX_tau || iteration==SampleSize,
0354                 file_index = file_index + 1;
0355                 if run_index<MAX_tau,
0356                     stoH = stoH(:,:,1:run_index);
0357                     stoJJ = stoJJ(:,:,1:run_index);
0358                     stoLRE = stoLRE(:,:,1:run_index);
0359                 end
0360                 save([IdentifDirectoryName '/' M_.fname '_identif_' int2str(file_index) '.mat'], 'stoH', 'stoJJ', 'stoLRE')
0361                 run_index = 0;
0362                 stoH = zeros(size(stoH));
0363                 stoJJ = zeros(size(stoJJ));
0364                 stoLRE = zeros(size(stoLRE));
0365                 
0366             end
0367             
0368             if SampleSize > 1,
0369 %                 if exist('OCTAVE_VERSION') || options_.console_mode,
0370 %                     console_waitbar(0,iteration/SampleSize);
0371 %                 else
0372                     dyn_waitbar(iteration/SampleSize,h,['MC identification checks ',int2str(iteration),'/',int2str(SampleSize)])
0373 %                 end
0374             end
0375         end
0376         
0377     end
0378     
0379     
0380     if SampleSize > 1,
0381         if exist('OCTAVE_VERSION') || options_.console_mode,
0382             fprintf('\n');
0383             diary on;
0384         else
0385             close(h),
0386         end
0387         normTAU=std(TAU')';
0388         normLRE=std(LRE')';
0389         normGAM=std(GAM')';
0390         normaliz1=std(pdraws);
0391         iter=0;
0392         for ifile_index = 1:file_index,
0393             load([IdentifDirectoryName '/' M_.fname '_identif_' int2str(ifile_index) '.mat'], 'stoH', 'stoJJ', 'stoLRE')
0394             for irun=1:size(stoH,3),
0395                 iter=iter+1;
0396                 siJnorm(iter,:) = vnorm(stoJJ(:,:,irun)./repmat(normGAM,1,nparam)).*normaliz1;
0397                 siHnorm(iter,:) = vnorm(stoH(:,:,irun)./repmat(normTAU,1,nparam)).*normaliz1;
0398                 siLREnorm(iter,:) = vnorm(stoLRE(:,:,irun)./repmat(normLRE,1,nparam-offset)).*normaliz1(offset+1:end);
0399             end
0400             
0401         end
0402         idemoments.siJnorm = siJnorm;
0403         idemodel.siHnorm = siHnorm;
0404         idelre.siLREnorm = siLREnorm;
0405         save([IdentifDirectoryName '/' M_.fname '_identif.mat'], 'pdraws', 'idemodel', 'idemoments', 'idelre', ... %'indJJ', 'indH', 'indLRE', ...
0406             'TAU', 'GAM', 'LRE','-append')
0407     else
0408         siJnorm = idemoments_point.siJnorm;
0409         siHnorm = idemodel_point.siHnorm;
0410         siLREnorm = idelre_point.siLREnorm;
0411     end
0412     
0413 else
0414     load([IdentifDirectoryName '/' M_.fname '_identif'])
0415 %     identFiles = dir([IdentifDirectoryName '/' M_.fname '_identif_*']);
0416     parameters = store_options_ident.parameter_set;
0417     options_ident.parameter_set = parameters;
0418     options_ident.prior_mc=size(pdraws,1);
0419     SampleSize = options_ident.prior_mc;
0420     options_.options_ident = options_ident;
0421 end  
0422 
0423 if nargout>3 && iload,
0424     filnam = dir([IdentifDirectoryName '/' M_.fname '_identif_*.mat']);
0425     H=[];
0426     JJ = [];
0427     gp = [];
0428     for j=1:length(filnam),
0429         load([IdentifDirectoryName '/' M_.fname '_identif_',int2str(j),'.mat']);
0430         H = cat(3,H, stoH(:,abs(iload),:));
0431         JJ = cat(3,JJ, stoJJ(:,abs(iload),:));
0432         gp = cat(3,gp, stoLRE(:,abs(iload),:));
0433         
0434     end
0435 end
0436 
0437 if iload,
0438     disp(['Testing ',parameters])
0439     disp_identification(idehess_point.params, idemodel_point, idemoments_point, name);
0440     plot_identification(idehess_point.params,idemoments_point,idehess_point,idemodel_point,idelre_point,advanced,parameters,name,IdentifDirectoryName);
0441 end
0442 if SampleSize > 1,
0443     fprintf('\n')
0444     disp('Testing MC sample')
0445     disp_identification(pdraws, idemodel, idemoments, name);
0446     plot_identification(pdraws,idemoments,idehess_point,idemodel,idelre,advanced,'MC sample - ',name, IdentifDirectoryName);
0447     if advanced,
0448         jcrit=find(idemoments.ino);
0449         if length(jcrit)<SampleSize,
0450             if isempty(jcrit),
0451                 [dum,jmax]=max(idemoments.cond);
0452                 fprintf('\n')
0453                 tittxt = 'Draw with HIGHEST condition number';
0454                 fprintf('\n')
0455                 disp(['Testing ',tittxt, '. Press ENTER']), pause(5),
0456                 if ~iload,
0457                     [idehess_max, idemoments_max, idemodel_max, idelre_max, derivatives_info_max] = ...
0458                         identification_analysis(pdraws(jmax,:),indx,indexo,options_ident,dataset_, prior_exist, name_tex,1);
0459                     save([IdentifDirectoryName '/' M_.fname '_identif.mat'], 'idehess_max', 'idemoments_max','idemodel_max', 'idelre_max', 'jmax', '-append');
0460                 end
0461                 disp_identification(pdraws(jmax,:), idemodel_max, idemoments_max, name);
0462                 close all,
0463                 plot_identification(pdraws(jmax,:),idemoments_max,idehess_max,idemodel_max,idelre_max,1,tittxt,name,IdentifDirectoryName);
0464                 [dum,jmin]=min(idemoments.cond);
0465                 fprintf('\n')
0466                 tittxt = 'Draw with SMALLEST condition number';
0467                 fprintf('\n')
0468                 disp(['Testing ',tittxt, '. Press ENTER']), pause(5),
0469                 if ~iload,
0470                     [idehess_min, idemoments_min, idemodel_min, idelre_min, derivatives_info_min] = ...
0471                         identification_analysis(pdraws(jmin,:),indx,indexo,options_ident,dataset_, prior_exist, name_tex,1);
0472                     save([IdentifDirectoryName '/' M_.fname '_identif.mat'], 'idehess_min', 'idemoments_min','idemodel_min', 'idelre_min', 'jmin', '-append');
0473                 end
0474                 disp_identification(pdraws(jmin,:), idemodel_min, idemoments_min, name);
0475                 close all,
0476                 plot_identification(pdraws(jmin,:),idemoments_min,idehess_min,idemodel_min,idelre_min,1,tittxt,name,IdentifDirectoryName);
0477             else
0478                 for j=1:length(jcrit),
0479                     tittxt = ['Rank deficient draw n. ',int2str(j)];
0480                     fprintf('\n')
0481                     disp(['Testing ',tittxt, '. Press ENTER']), pause(5),
0482                     if ~iload,
0483                         [idehess_(j), idemoments_(j), idemodel_(j), idelre_(j), derivatives_info_(j)] = ...
0484                             identification_analysis(pdraws(jcrit(j),:),indx,indexo,options_ident,dataset_, prior_exist, name_tex,1);
0485                     end
0486                     disp_identification(pdraws(jcrit(j),:), idemodel_(j), idemoments_(j), name);
0487                     close all,
0488                     plot_identification(pdraws(jcrit(j),:),idemoments_(j),idehess_(j),idemodel_(j),idelre_(j),1,tittxt,name,IdentifDirectoryName);
0489                 end
0490                 if ~iload,
0491                     save([IdentifDirectoryName '/' M_.fname '_identif.mat'], 'idehess_', 'idemoments_','idemodel_', 'idelre_', 'jcrit', '-append');
0492                 end
0493             end
0494         end
0495     end
0496 end
0497 
0498 if exist('OCTAVE_VERSION')
0499     warning('on'),
0500 else
0501     warning on,
0502 end
0503 
0504 disp(' ')
0505 disp(['==== Identification analysis completed ====' ]),
0506 disp(' ')
0507 disp(' ')

Generated on Mon 21-May-2012 02:42:43 by m2html © 2005