trunk: changed to GPL headers in Marco Ratto's files
git-svn-id: https://www.dynare.org/svn/dynare/trunk@2433 ac1d8469-bf42-47a9-8791-bf33cf982152time-shift
parent
52458e94ff
commit
e287be53ca
|
@ -1,19 +1,25 @@
|
||||||
function x0=dynare_sensitivity(options_gsa)
|
function x0=dynare_sensitivity(options_gsa)
|
||||||
% Part of the Sensitivity Analysis Toolbox for DYNARE
|
% Frontend to the Sensitivity Analysis Toolbox for DYNARE
|
||||||
%
|
%
|
||||||
% Written by Marco Ratto, 2006
|
|
||||||
% Joint Research Centre, The European Commission,
|
|
||||||
% (http://eemc.jrc.ec.europa.eu/),
|
|
||||||
% marco.ratto@jrc.it
|
|
||||||
%
|
|
||||||
% Disclaimer: This software is not subject to copyright protection and is in the public domain.
|
|
||||||
% It is an experimental system. The Joint Research Centre of European Commission
|
|
||||||
% assumes no responsibility whatsoever for its use by other parties
|
|
||||||
% and makes no guarantees, expressed or implied, about its quality, reliability, or any other
|
|
||||||
% characteristic. We would appreciate acknowledgement if the software is used.
|
|
||||||
% Reference:
|
% Reference:
|
||||||
% M. Ratto, Global Sensitivity Analysis for Macroeconomic models, MIMEO, 2006.
|
% M. Ratto, Global Sensitivity Analysis for Macroeconomic models, MIMEO, 2006.
|
||||||
|
|
||||||
|
% Copyright (C) 2008 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 M_ options_ oo_ bayestopt_ estim_params_
|
global M_ options_ oo_ bayestopt_ estim_params_
|
||||||
|
|
||||||
|
|
|
@ -1,10 +1,25 @@
|
||||||
function [f0, x, ig] = mr_gstep(func0,x,htol0,varargin)
|
function [f0, x, ig] = mr_gstep(func0,x,htol0,varargin)
|
||||||
% Copyright (C) 2005 Marco Ratto
|
|
||||||
%
|
|
||||||
% function [f0, x] = mr_gstep(func0,x,htol0,varargin)
|
% function [f0, x] = mr_gstep(func0,x,htol0,varargin)
|
||||||
%
|
%
|
||||||
% Gibbs type step in optimisation
|
% Gibbs type step in optimisation
|
||||||
|
|
||||||
|
% Copyright (C) 2006 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 bayestopt_ options_
|
global bayestopt_ options_
|
||||||
persistent h1
|
persistent h1
|
||||||
|
|
||||||
|
|
|
@ -1,11 +1,11 @@
|
||||||
% Copyright (C) 2004 Marco Ratto
|
function [hessian_mat, gg, htol1, ihh, hh_mat0] = mr_hessian(func,x,hflag,htol0,varargin)
|
||||||
% adapted from Michel Juillard original rutine hessian.m
|
|
||||||
%
|
|
||||||
% [hessian_mat, gg, htol1, ihh, hh_mat0] = mr_hessian(func,x,hflag,htol0,varargin)
|
% [hessian_mat, gg, htol1, ihh, hh_mat0] = mr_hessian(func,x,hflag,htol0,varargin)
|
||||||
%
|
%
|
||||||
% numerical gradient and Hessian, with 'automatic' check of numerical
|
% numerical gradient and Hessian, with 'automatic' check of numerical
|
||||||
% error
|
% error
|
||||||
%
|
%
|
||||||
|
% adapted from Michel Juillard original rutine hessian.m
|
||||||
|
%
|
||||||
% func = name of the function: func must give two outputs:
|
% func = name of the function: func must give two outputs:
|
||||||
% - the log-likelihood AND the single contributions at times t=1,...,T
|
% - the log-likelihood AND the single contributions at times t=1,...,T
|
||||||
% of the log-likelihood to compute outer product gradient
|
% of the log-likelihood to compute outer product gradient
|
||||||
|
@ -23,9 +23,24 @@
|
||||||
% derivatives
|
% derivatives
|
||||||
%
|
%
|
||||||
% varargin: other parameters of func
|
% varargin: other parameters of func
|
||||||
%
|
|
||||||
|
|
||||||
function [hessian_mat, gg, htol1, ihh, hh_mat0] = mr_hessian(func,x,hflag,htol0,varargin)
|
% Copyright (C) 2004-2008 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 options_ bayestopt_
|
global options_ bayestopt_
|
||||||
persistent h1 htol
|
persistent h1 htol
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,4 @@
|
||||||
function [xparam1, hh, gg, fval, igg] = newrat(func0, x, hh, gg, igg, ftol0, nit, flagg, varargin)
|
function [xparam1, hh, gg, fval, igg] = newrat(func0, x, hh, gg, igg, ftol0, nit, flagg, varargin)
|
||||||
%
|
|
||||||
% Copyright (C) 2004 Marco Ratto
|
|
||||||
%
|
|
||||||
% [xparam1, hh, gg, fval, igg] = newrat(func0, x, hh, gg, igg, ftol0, nit, flagg, varargin)
|
% [xparam1, hh, gg, fval, igg] = newrat(func0, x, hh, gg, igg, ftol0, nit, flagg, varargin)
|
||||||
%
|
%
|
||||||
% Optimiser with outer product gradient and with sequences of univariate steps
|
% Optimiser with outer product gradient and with sequences of univariate steps
|
||||||
|
@ -27,7 +24,23 @@ function [xparam1, hh, gg, fval, igg] = newrat(func0, x, hh, gg, igg, ftol0, nit
|
||||||
% flagg = 2, full numerical Hessian
|
% flagg = 2, full numerical Hessian
|
||||||
%
|
%
|
||||||
% varargin = list of parameters for func0
|
% varargin = list of parameters for func0
|
||||||
|
|
||||||
|
% Copyright (C) 2004-2008 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 bayestopt_
|
global bayestopt_
|
||||||
icount=0;
|
icount=0;
|
||||||
|
|
Loading…
Reference in New Issue