Home > matlab > test_for_deep_parameters_calibration.m

test_for_deep_parameters_calibration

PURPOSE ^

Issues a warning is some of the parameters are NaNs.

SYNOPSIS ^

function test_for_deep_parameters_calibration(M_)

DESCRIPTION ^

 Issues a warning is some of the parameters are NaNs.

 INPUTS
   M_    [structure]   Description of the (simulated or estimated) model.
  
 OUTPUTS
   none
    
 ALGORITHM
   none
    
 SPECIAL REQUIREMENTS
   none

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function test_for_deep_parameters_calibration(M_)
0002 % Issues a warning is some of the parameters are NaNs.
0003 %
0004 % INPUTS
0005 %   M_    [structure]   Description of the (simulated or estimated) model.
0006 %
0007 % OUTPUTS
0008 %   none
0009 %
0010 % ALGORITHM
0011 %   none
0012 %
0013 % SPECIAL REQUIREMENTS
0014 %   none
0015 
0016 % Copyright (C) 2010 Dynare Team
0017 %
0018 % This file is part of Dynare.
0019 %
0020 % Dynare is free software: you can redistribute it and/or modify
0021 % it under the terms of the GNU General Public License as published by
0022 % the Free Software Foundation, either version 3 of the License, or
0023 % (at your option) any later version.
0024 %
0025 % Dynare is distributed in the hope that it will be useful,
0026 % but WITHOUT ANY WARRANTY; without even the implied warranty of
0027 % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0028 % GNU General Public License for more details.
0029 %
0030 % You should have received a copy of the GNU General Public License
0031 % along with Dynare.  If not, see <http://www.gnu.org/licenses/>.
0032 plist = list_of_parameters_calibrated_as_NaN(M_);
0033 if ~isempty(plist)
0034     message = ['Some of the parameters have no value (' ];
0035     for i=1:size(plist,1)
0036         if i<size(plist,1)
0037             message = [message, deblank(plist(i,:)) ', '];
0038         else
0039             message = [message, deblank(plist(i,:)) ')'];
0040         end
0041     end
0042     tmp = dbstack;
0043     message = [message, ' when using ' tmp(2).name '. '];
0044     message = [message, 'If these parameters are not initialized in a steadystate file, Dynare may not be able to solve the model...'];
0045     message_id  = 'Dynare:ParameterCalibration:NaNValues';
0046     warning(message_id,message);
0047 end

Generated on Tue 22-May-2012 02:40:23 by m2html © 2005