Commit Graph

5430 Commits (943db6fb24d9e4b01f31d084696bb8aec9010ff4)

Author SHA1 Message Date
Frédéric Karamé 888cf1eeff Updated particles. 2015-05-27 16:00:09 +02:00
Frédéric Karamé 38a276fb08 restore the default value for distribution_approximation 2015-05-27 14:57:01 +02:00
Frédéric Karamé df67efcb7c add an exception for the use of gaussian filters and gradient-based estimation methods 2015-05-27 14:37:50 +02:00
Stéphane Adjemian (Hermes) 96b484d89c Updated particles. 2015-05-27 14:35:55 +02:00
Michel Juillard 127730d731 solve bugs when there are lags of exogenous variables on more than one
period in deterministic models.
2015-05-27 12:22:32 +02:00
Stéphane Adjemian (Hermes) ccd4e40b49 Merge branch 'master' into rewrite-nonlinear-filters
Conflicts:
	.gitmodules
	tests/particle/dsge_base2.mod
2015-05-27 12:18:33 +02:00
Michel Juillard eefa7bb70a fixing problem with endogenous_terminal_period 2015-05-27 10:23:14 +02:00
Michel Juillard 1b822a9105 fix calls to dynare_solve() when Jacobian of function must be computed
numerically. Fix call to dynare_solve() in simulation_core()
2015-05-26 15:51:09 +02:00
Houtan Bastani 90c4f834f2 fix typo introduced in f03839cf12 2015-05-26 12:11:24 +02:00
Michel Juillard d81dda5044 fixing bug in last commit 2015-05-25 18:52:46 +02:00
Michel Juillard 3ef5bc2989 Merge branch 'master' into new_ep 2015-05-25 17:20:23 +02:00
Michel Juillard 92a33f9792 changed another call to dynare_solve() forgotten in last commit 2015-05-25 17:15:09 +02:00
Michel Juillard f03839cf12 removed "global options_" in dynare_solve.m and made it an
argument. Modified all calling functions.
2015-05-25 17:15:09 +02:00
Michel Juillard a36fd53eff fixing extended-path 2015-05-25 09:43:21 +02:00
Michel Juillard b3047c9742 Merge branch 'master' into new_ep 2015-05-23 18:26:07 +02:00
Houtan Bastani d5cb78bbea fix typo introduced in 89828e56cc 2015-05-20 10:12:24 +02:00
Houtan Bastani 89828e56cc preprocessor: add proprosal_distribution and student_degrees_of_freedom options to estimation. closes #925 2015-05-19 12:31:22 +02:00
Stéphane Adjemian (Hermes) 8b6040717a Added missing semicolon. 2015-05-18 18:00:09 +02:00
Johannes Pfeifer cb1fc3ec3c Lift unnecessary restriction of not allowing simpsa with infinite bounds
Introduction of options_.huge_number makes this redundant
2015-05-13 20:33:14 +02:00
Houtan Bastani e5df26a6e8 preprocessor: add use_tarb option to estimation. #940 2015-05-13 15:32:24 +02:00
Houtan Bastani 902a5d2788 ensure that mex file exists before doing comparison 2015-05-12 10:55:24 +02:00
Johannes Pfeifer 646658a0f2 Add missing deblank to disp_dr.m 2015-05-11 17:40:03 +02:00
Johannes Pfeifer 3c3b255025 Clarify that output of mode_check.m is minus likelihood/posterior 2015-05-11 17:39:26 +02:00
Stéphane Adjemian 9d8823dd73 Merge pull request #932 from JohannesPfeifer/t_dist
Unit test and cosmetic changes for t-distribution
2015-05-10 23:29:17 +02:00
Michel Juillard a5a5490a12 adding feature to recompile MEX files only if the model has
changed (not activated yet)
detail of compilation code moved from preprocessor (ModFile.cc) to
./matlab/utilities/general/dyn_mex.m
2015-05-10 18:16:53 +02:00
Johannes Pfeifer b67e9626f7 Add more information to header of rand_multivariate_student.m 2015-05-10 10:06:42 +02:00
Stéphane Adjemian 16a29d58a6 Merge pull request #930 from JohannesPfeifer/rename_hessian
Make sure that no variable is named hessian
2015-05-10 09:09:43 +02:00
Johannes Pfeifer e76f81740f Make sure that no variable is named hessian. 2015-05-10 08:17:40 +02:00
Stéphane Adjemian 29f9cb4d53 Merge pull request #929 from JohannesPfeifer/delete_stale_files
Delete stale files from previous MCMC runs
2015-05-09 22:47:25 +02:00
Stéphane Adjemian (Charybdis) b8eb0ff72d Added online help to prior command (cli). 2015-05-09 22:36:19 +02:00
Johannes Pfeifer fa1f7794d5 Delete stale files from previous MCMC runs
Closes #566. Also adds cosmetic changes to headers of affected routines
2015-05-09 15:13:59 +02:00
Stéphane Adjemian 450520e946 Merge pull request #926 from JohannesPfeifer/return_values
Make sure non_linear_dsge_likelihood.m and dsge_var_likelihood.m retu…
2015-05-09 14:27:03 +02:00
Johannes Pfeifer 8aec696b95 Fix various copy and paste errors in check_input_arguments.m
During moving to a separate function, not all variables had been renamed
2015-05-09 08:22:31 +02:00
Johannes Pfeifer 481c470ac9 Make sure non_linear_dsge_likelihood.m and dsge_var_likelihood.m return correct error codes if prior or likelihood are Inf or NaN
Closes #284
2015-05-09 08:03:55 +02:00
Stéphane Adjemian 3bcb89bd72 Merge pull request #893 from JohannesPfeifer/Fix_message
Fix crash in error message display of perfect_foresight_setup.m when mor...
2015-05-07 17:23:25 +02:00
Stéphane Adjemian (Hermes) f960e7bb68 Merged branch simpsa-inf-fix. 2015-05-07 16:01:43 +02:00
Stéphane Adjemian (Hermes) 6d0dfc2d3f Do not use hard coded value for the finite interval replacing unbounded intervals in simpsa and simulated annealing algorithms. 2015-05-07 15:59:46 +02:00
Stéphane Adjemian f26cec2430 Merge pull request #904 from JohannesPfeifer/mode_compute7_octave
Fix compatibility of mode_compute=7
2015-05-07 15:16:15 +02:00
Stéphane Adjemian de526eae57 Merge pull request #906 from JohannesPfeifer/table_display
Cosmetic fixes to the on-screen display of tables
2015-05-07 15:15:38 +02:00
Stéphane Adjemian efc5ec7002 Merge pull request #908 from JohannesPfeifer/optimizer_doc
Add documentation for new optimizers
2015-05-07 15:12:15 +02:00
Stéphane Adjemian ddc7464b9b Merge pull request #911 from JohannesPfeifer/MH_cosmetics
Cosmetic Fixes to Metropolis-Hastings routines
2015-05-07 14:29:27 +02:00
Stéphane Adjemian 971142131e Merge pull request #918 from JohannesPfeifer/Geweke_fix
Fix Geweke convergence when used with load_mh_file
2015-05-07 14:09:36 +02:00
Stéphane Adjemian cd509427bf Merge pull request #919 from JohannesPfeifer/Trace_Plot
Add possibility to plot posterior density to trace_plot.m
2015-05-07 14:09:11 +02:00
Stéphane Adjemian 0e0cb1a191 Merge pull request #920 from JohannesPfeifer/Bayesian_IRF_display
Fix plotting of Bayesian IRFs where IRFs turn from negative to positive.
2015-05-07 14:07:21 +02:00
Stéphane Adjemian 3a79f28941 Merge pull request #921 from JohannesPfeifer/dynasave
Add check for field existence to dynasave.m
2015-05-07 12:49:31 +02:00
Stéphane Adjemian 7e3778df7f Merge pull request #922 from JohannesPfeifer/identification_JJ_unit_root
Add check for presence of NaN in JJ to identification_analysis.m
2015-05-07 12:48:49 +02:00
Marco Ratto e2b59630c1 diffuse_kalman_tol not properly triggered 2015-05-07 10:18:55 +02:00
Johannes Pfeifer 0c7b4f542c Add check for presence of NaN in JJ to identification_analysis.m
Usually happens when model has a unit root and unconditional second moments are NaN
2015-05-06 16:14:45 +02:00
Michel Juillard f2617fcf74 deterministic simulations: more efficient manner to build the Jacobian matrix
of the stacked system. Gains is not as much as expected.
2015-05-06 11:16:53 +02:00
Johannes Pfeifer 7d263dcd2f Add check for field existence to dynasave.m
Otherwise, if simulations do not exist, a cryptic crash happens
2015-05-05 16:09:05 +02:00
Johannes Pfeifer b8c6c87908 Fix plotting of Bayesian IRFs where IRFs turn from negative to positive. 2015-05-05 16:02:37 +02:00
Johannes Pfeifer 6d7cbe33c5 Add possibility to plot posterior density to trace_plot.m 2015-05-04 10:49:24 +02:00
Johannes Pfeifer 50f0dadec8 Fix Geweke convergence when used with load_mh_file
By accessing mh_replic instead of NumberOfDraws, the diagnostics were not correctly computed on the full chain
2015-05-02 14:23:23 +02:00
Houtan Bastani e550aa806a change convert_oo_ to be forward compatible 2015-04-30 15:25:54 +02:00
Houtan Bastani 9cf352e471 bug fix in check_valid_ver 2015-04-30 15:24:12 +02:00
Houtan Bastani a93e0157e4 add utilities to convert oo_ between different versions of dynare, #546 2015-04-30 14:45:53 +02:00
Johannes Pfeifer 67b3c5deef Cosmetic changes to masterParallel.m 2015-04-30 09:04:09 +02:00
Houtan Bastani 7570328c0d reporting: submodule update. closes #869 2015-04-29 16:22:12 +02:00
Marco Ratto 6a17fe5de3 Fix provisions for matlab 8.5 win32 bits. 2015-04-29 11:33:14 +02:00
Houtan Bastani 07c74f7f7d reporting: submodule update (to be reverted when Debian tex distro is finally updated) 2015-04-28 17:39:04 +02:00
Houtan Bastani fa5eb67d91 reporting: submodule update (to deal with Debian's outdated LaTeX distro. Revert when servers are updated), #867 2015-04-28 16:39:02 +02:00
Houtan Bastani c9b404fc1b reporting: submodule update, #867 2015-04-27 18:28:11 +02:00
Houtan Bastani 18e9521450 preprocessor: add dirname option to estimation. closes #910 2015-04-27 11:59:21 +02:00
Houtan Bastani 17e03a82e3 fix comment 2015-04-27 11:07:52 +02:00
Johannes Pfeifer b4941c02d3 Cosmetic Fixes to Metropolis-Hastings routines
- Adds comments and headers and fixes typos in previous ones
- Make naming in random_walk_metropolis_hastings_core.m more intuitive
2015-04-25 19:28:16 +02:00
Johannes Pfeifer 9408319e48 Cosmetic changes related to solvopt.m 2015-04-24 12:31:27 +02:00
Houtan Bastani 4ffebeee2e dseries: submodule update 2015-04-23 14:15:47 +02:00
Sébastien Villemot db272f114b Compatibility fixes for MATLAB <= 7.7.
The tilde syntax was introduced in MATLAB 7.8.
2015-04-22 16:45:15 +02:00
Johannes Pfeifer 8285121f9b Allow selection of tolerance for display of decision rules 2015-04-22 15:37:35 +02:00
Johannes Pfeifer 20a4f551ed Improve display of decision rules by accounting for variable lengths
Also cleans up file by factoring code
2015-04-22 15:29:04 +02:00
Johannes Pfeifer 0dac179944 Improve display of tables
Closes #892 by allowing for optional inputs for cell lengths. Replaces centering of headers by right-flush to improve readability.
2015-04-22 15:26:03 +02:00
Sébastien Villemot f86b91d3d6 Perfect foresight solver: inform the user when we switch to a homotopy method. 2015-04-22 14:44:39 +02:00
Houtan Bastani ac15eda6de Revert "Add check for valid filename"
This reverts commit 39c7b793f2.

(would not be necessary if 9f7d3524e9 had
been rebased)
2015-04-22 13:55:35 +02:00
Houtan Bastani 57f89d6843 Merge pull request #905 from JohannesPfeifer/filename_check
Add check for valid filename
2015-04-22 13:47:15 +02:00
Johannes Pfeifer 9f7d3524e9 Add check for valid filename
Uses the same restrictions as variable names.
2015-04-22 13:30:09 +02:00
Sébastien Villemot 8ab1239d79 Fix handling of warnings in perfect foresight solver with homotopy. 2015-04-22 12:23:20 +02:00
Houtan Bastani df697febcb dseries: submodule update 2015-04-22 11:38:36 +02:00
Johannes Pfeifer 8eaa645800 Fix compatibility of mode_compute=7
Uses wrapper as for mode_compute=3 to restore to conform to Octave syntax
2015-04-22 11:08:32 +02:00
Johannes Pfeifer 39c7b793f2 Add check for valid filename
Uses the same restrictions as variable names.
2015-04-22 10:57:10 +02:00
Johannes Pfeifer c6c5cd8ce8 Allow Inf bounds in simpsa by replacing them with big finite number
Closes #585
2015-04-21 16:26:46 +02:00
Johannes Pfeifer 3dee87c243 Fix crash in unit test fs2000_smoother_only
For calibrated models, the param_vals field does not exist
2015-04-20 16:45:51 +02:00
Johannes Pfeifer 31cd80e9a9 Fix crash in error message display of perfect_foresight_setup.m when more than one variable is not present in current period
Concatenation otherwise crashes due to non-conformable matrices
2015-04-19 10:52:22 +02:00
Marco Ratto 8ab8d46281 small fix in matlab annotation 2015-04-17 09:16:54 +02:00
Stéphane Adjemian 0a27b71f7e Merge pull request #886 from rattoma/gsa
Enhance and harmonize reduced form mapping routine
2015-04-17 08:41:32 +02:00
Johannes Pfeifer bc6cf0345f Clean up csminwel1.m
Adds documentation and puts calling of numerical gradient to nested function as previously suggested in comment at the bottom of file
2015-04-17 07:05:01 +02:00
Johannes Pfeifer b629d3ca19 Cosmetic changes to csminwel routines
Mostly adds documentation
2015-04-17 07:05:00 +02:00
Johannes Pfeifer 84f0060cbd Fix bug where inverse Hessian from csminwel1.m was taken as Hessian 2015-04-17 07:05:00 +02:00
Stéphane Adjemian (Charybdis) 1970951d1f Merge branch 'johannes_fix_simulated_annealing_and_other_optimization_related_issues' 2015-04-16 22:31:07 +02:00
Marco Ratto b0f4f2af78 Harmonize use of front-end mcf_analysis.m in GSA and identification routines. 2015-04-16 18:25:35 +02:00
Marco Ratto 57e9b9fa8b Revived reduced form mapping routine:
1) use new mcf_analysis.m;
2) use generic filtering when threshold does not work;
3) make log-tranformed mapping meaningful and comparable to baseline;
3) harmonize names of files saved and reduced number of directories created;
2015-04-16 16:13:16 +02:00
Marco Ratto 0faf6e1981 Allow inverse transform and set minimum threshold for lam 2015-04-16 16:13:00 +02:00
Marco Ratto ae6302c348 Added output argument to mcf_analysis.m 2015-04-16 16:09:39 +02:00
Marco Ratto 4e1e7732fd fix graphic issues with eps 2015-04-16 12:30:27 +02:00
Marco Ratto 8d679bff6f missing bits in fixes to graphical issues #881. 2015-04-16 08:52:42 +02:00
Marco Ratto 41cebf7e4e - fix nograph option in GSA graphical output
- fix graphical output issues on unix
2015-04-15 22:54:36 +02:00
Stéphane Adjemian (Charybdis) f0770186ca Exhanged mode_compute=2 and mode_compute=102.
These options are for the simulated annealing algorithm, the Mathworks' global optimization
toolbox is mandatory for mode_compute=102. The first option relies on a
free implementation (works also with Octave).
2015-04-15 12:42:08 +02:00
Stéphane Adjemian (Charybdis) da2c529ee7 Merge branch 'marco_gsa_fixes' 2015-04-14 15:54:59 +02:00
Johannes Pfeifer 1a6afc0fdb Restore compatibility of recursive estimation with new data interface
Use dataset_ structure instead of reconstructing data to plot. Eliminates crashes
2015-04-14 15:12:25 +02:00
Marco Ratto 0bd8fef202 - Various bug fixes on moment calibration
- Bug fixes on plots showing restrictions
- Improved and increased graphical info
2015-04-14 12:24:49 +02:00
Marco Ratto ffc4b7480c - improved plots with MATLAB annotations [trapped in octave] and different colors
- use uimenu to get the name of the observable associated to each CDF from MATLAB plots
[trapped in octave]
- also checks multiple significant parameters by individual observable
2015-04-14 12:16:50 +02:00
Marco Ratto a44b3fbfe7 Bug fixed for incomplete stock matrices of log-posterior kernel and steady state
[used in gsa/filt_mc_.m]
2015-04-14 12:10:46 +02:00
Marco Ratto e32cbf626f Fixed bug when neighborhood_width is used : MC option must be forced. 2015-04-14 12:06:25 +02:00
Marco Ratto ca8f0ea006 Harmonize filters/likelihood with smoothers by using new option diffuse_kalman_tol 2015-04-08 15:49:12 +02:00
Marco Ratto fe48de4406 Re-set default of new option diffuse_kalman_tol to 1e-6:
former hardcoded value was 1e-6 in the univariate smoother (i.e. the one most often used).
Updated documentation.
2015-04-08 15:44:39 +02:00
Johannes Pfeifer 49d4643481 Fix copy and paste typo in gmhmaxlik.m 2015-04-06 12:04:11 +02:00
Johannes Pfeifer d1a80acb44 Replace non-available simulated annealing by Matlab's routine
Closes #814
2015-04-06 11:28:32 +02:00
Johannes Pfeifer 39ed3eb3f0 Fix bugs related to allowing mode_compute to be a string
Crashes otherwise
2015-04-06 11:24:42 +02:00
Johannes Pfeifer a81c9da9a2 Add simulated_annealing.m to optimizers
Restores compatibility of mode_compute=102
2015-04-06 11:08:20 +02:00
Johannes Pfeifer 405b1f7368 Add solvopt.m to Dynare optimizers
Restores compatibility of mode_compute=101
2015-04-06 11:05:12 +02:00
Houtan Bastani 23b322d6c6 Merge pull request #866 from JohannesPfeifer/mode_check
Remove hard-coded coloring of legend in mode_check.m
2015-04-03 18:07:14 +02:00
Stéphane Adjemian (Charybdis) 6aa5ceabb2 Fixed bug introduced in 363c4a61222103fda22adff9bdb1115a6073428a. 2015-04-03 18:02:03 +02:00
Stéphane Adjemian (Charybdis) 090c4fedbd Added new option (diffuse_kalman_tol) and fixed tolerance paremeters in diffuse smoother routines. 2015-04-03 18:02:03 +02:00
Marco Ratto e97e5c3407 Exclude zero columns of T from Kitagawa transformation, since ordschur is extremely noisy for multiple zero eigenvalues.
This can make a lot of difference for large models that have hundreds of definitions.
2015-04-03 18:02:03 +02:00
Marco Ratto 5297836577 Harmonize criteria for exiting diffuse steps in likelihood with the smoother.
Since initial Pinf is well scaled to unity, crit1= 1.e-6 is used for smoother and should also apply to likelihood evaluations.
2015-04-03 18:02:03 +02:00
Marco Ratto 7c838b133f Use local variables for restrict var list, to avoid overwriting the global and messing likelihood evaluations later on. 2015-04-03 18:02:03 +02:00
Johannes Pfeifer 8cc9fbd69a Remove hard-coded coloring of legend in mode_check.m
Now displays correct colors with new Matlab plot interface (>2014a)
2015-04-02 20:52:49 +02:00
Stéphane Adjemian f9154273d0 Merge pull request #854 from JohannesPfeifer/smoother_var_initialization_fix
Fix size of filtered variables matrix
2015-04-01 17:59:12 +02:00
Stéphane Adjemian (Charybdis) f3d1a6c68e Merge branch 'master' into marco_analytic_derivation 2015-04-01 16:41:38 +02:00
Johannes Pfeifer 27403fb2dd Add check whether initial prior is Inf
Requires adding fourth output argument of priordens.m that stores position of problematic parameter.
2015-04-01 16:30:46 +02:00
Johannes Pfeifer 9c3c0d727f Add check for point priors and force user to fix this parameter.
Traps Inf-prior
2015-04-01 16:29:18 +02:00
Marco Ratto b4a8ad8aa4 Fix mex path for win64 bit 2015-04-01 14:43:52 +02:00
Marco Ratto 214dc74723 - Fixed bugs around analytic derivation.
- Fixed test routine, eliminating diffuse filter.
- Trapped incompatibility of diffuse filter with analytic derivation.
2015-04-01 09:00:51 +02:00
Stéphane Adjemian 28f2e2abd0 Merge pull request #856 from rattoma/optimizer_number_5
Fixed issues related to newratflag.
2015-03-30 15:22:05 +02:00
Stéphane Adjemian ad0e0b6c1d Merge pull request #861 from JohannesPfeifer/steady_fix
Prevent crash if steady state cannot be computed
2015-03-30 15:17:46 +02:00
Stéphane Adjemian (Charybdis) 0e1dd779b9 Check that Dynare's routines are not overridden by other routines.
By default Dynare will temporarly change Matlab/Octave's path. Added an
option to force Dynare to keep the current path. Also check that the user
did not put dynare/matlab directory with all the subfolders in the path.

With this patch, we do not need to prefix Dynare routines with dyn_ or
dynare_ anymore.
2015-03-30 15:04:59 +02:00
Houtan Bastani 34c871b53c getenv provides one output on windows 2015-03-27 18:58:35 +01:00
Houtan Bastani 90e00b3871 fixes for windows 2015-03-27 17:29:10 +01:00
Houtan Bastani d7c253ae59 support 64-bit preprocessor, #862 2015-03-26 19:08:30 +01:00
Johannes Pfeifer 781e280610 Prevent crash if steady state cannot be computed
If e.g. the log of the steady state cannot be computed, the field oo_.dr.ys does not exist
2015-03-25 09:42:59 +01:00
Sébastien Villemot 80f512b90b ilu function has been implemented in Octave 4.0. 2015-03-18 16:03:41 +01:00
Sébastien Villemot aa1acec308 Remove obsolete warning code for Octave < 3.6. 2015-03-17 18:01:36 +01:00
Sébastien Villemot ec65f80617 Octave warning "matlab-incompatible" renamed to "language-extension" in 4.0. 2015-03-17 17:59:52 +01:00
Houtan Bastani 1a3d8d0b26 Provisions for MATLAB 8.5 (R2015a) 2015-03-16 14:44:06 +01:00
Stéphane Adjemian (Scylla) 6d7b72cb0d Merged with master 2015-03-13 15:53:18 +01:00
Marco Ratto c881cfff17 Fixed issues related to newratflag.
This options relates to alternative numerical hessian computations:

optim=('Hessian',1) is the default dynare numeric Hessian
optim=('Hessian',0) is the outer product gradient
optim=('Hessian',2) is the 'mixed' outer product gradient, where diagonal elements using second order derivation formula,

Both 0 and 2 cases require univariate filters, to ensure using maximum number of individual densities.
2015-03-12 17:24:21 +01:00
Johannes Pfeifer d4c0726026 Fix size of filtered variables matrix
Fixes crash occurring due to non-conformable matrices
2015-03-12 10:49:33 +01:00
Michel Juillard 87cb00bd7d fixing bug in calling sequence of *_dynamic function when using block option 2015-03-11 09:24:47 +01:00
Sébastien Villemot 6e0d919751 Fix issue with purely forward deterministic models with lags on exogenous.
Ref #617
2015-03-09 18:22:01 +01:00
Houtan Bastani 6db9f10353 preprocessor: remove use of tables completely as they were introduced in Matlab R2013b. #824 2015-03-09 17:59:05 +01:00
Houtan Bastani d77b5104d2 preprocessor: cell2table doesn’t exist in Octave 2015-03-09 17:16:59 +01:00
Michel Juillard 86f9e53ec6 dr_block: fixing bug in solve_foward_complete 2015-03-07 10:59:53 +01:00
Michel Juillard 265970c1c9 adding global test for identification for sbvar 2015-03-07 10:59:53 +01:00
Michel Juillard a53385ea28 dynare_solve: fix initial check for models with complementarity conditions 2015-03-07 10:10:35 +01:00
Stéphane Adjemian (Charybdis) de5c541ce6 Manually merged PR #807.
Fixed conflict related to the move of the perfect foresight related routines
in a subfolder.
2015-03-05 14:31:36 +01:00
Michel Juillard 0c1197c13f extended_path: fixing bug when initializing with linear approximation,
adding simple homotopy scheme (unfinished)
2015-03-04 09:43:14 +01:00
Michel Juillard a5c652f81a removing nefarious _ 2015-03-04 09:41:29 +01:00
Houtan Bastani 30428aeb17 preprocessor: add joint prior syntax, #824 2015-03-03 15:08:33 +01:00
Stéphane Adjemian 219b4fe547 Merge pull request #813 from JohannesPfeifer/model_diag
Add missing abs to unit root check in model_diagnostics.m
2015-03-01 16:35:31 +01:00
Stéphane Adjemian 511d621818 Merge pull request #851 from JohannesPfeifer/Estimation_Bugfixes
Estimation bugfixes
2015-03-01 16:33:51 +01:00
Stéphane Adjemian ba2c4db88c Merge pull request #816 from JohannesPfeifer/loglinear_steady_error
Integrate error from negative steady state with loglinear model into pri...
2015-03-01 16:30:29 +01:00
Johannes Pfeifer a7f380d8c0 Condition check for changed parameters on whether parameters are estimated in the first place
Fixes crash in master unit test
2015-03-01 13:36:21 +01:00
Johannes Pfeifer fe938c902a Fixed another bug related to options_.optim_opt being now initialized as an empty array
Finalizes  392486273e
2015-03-01 13:34:39 +01:00
Johannes Pfeifer 0ef7524977 Use dynare_minimize_objective for OSR computations 2015-02-28 20:37:10 +01:00
Stéphane Adjemian (Charybdis) 198a6ed7cf Removed three unused routines. 2015-02-27 18:54:12 +01:00
Stéphane Adjemian (Charybdis) 73cdaa3091 Replaced get_prior_info routine by prior routine.
This new routine gives the possibility to obtain a description of the
prior from the command line.

>> prior table

will display a table with the prior mean, prior mode, prior std, prior
bounds and prior HPD interval.

>> prior plot

will plot the prior densities.

>> prior optimize

will trigger the maximization of the prior density and display the
results (often, because of BK conditions or other issues, Dynare is even
not able to get the prior mode).

>> prior moments

will display the moments of the endogenous variables at the prior mode.

>> prior simulate

will run a Monte-Carlo, by sampling from the prior and discarding vector
of parameters such that the steady state does not exist or the BK
conditions are not met, and return an estimate of the effective prior
mass.
2015-02-27 17:12:04 +01:00
Stéphane Adjemian (Charybdis) daaed37782 Added new routines. 2015-02-27 17:05:11 +01:00
Stéphane Adjemian (Charybdis) eec1e77140 Removed last character if string is renurned in a variable. 2015-02-26 16:18:33 +01:00
Stéphane Adjemian (Charybdis) 4979f33f8b Added the possibility to return the generated line in a variable. 2015-02-26 16:10:44 +01:00
Stéphane Adjemian (Charybdis) 04ae10434c Beta prior. Do not return the prior mean of the prior density has two
modes (return the first mode).
2015-02-26 12:07:40 +01:00
Stéphane Adjemian (Charybdis) 392486273e Fixed bug (options_.optim_opt is now initialized as an empty array). 2015-02-26 08:43:30 +01:00
Stéphane Adjemian (Charybdis) 0bb413e8fa Merge branch 'experimental-optimizers' 2015-02-24 20:44:39 +01:00
Stéphane Adjemian (Charybdis) 83981125c9 Added missing routine and fixed licence header. 2015-02-24 20:42:19 +01:00
Stéphane Adjemian (Charybdis) 5ef340b8cf Rewrote gmhmaxlik routine (mode_compute==6). 2015-02-24 20:34:35 +01:00
Houtan Bastani e19f03b420 replace reporting code with submodule. closes #811 2015-02-24 16:38:36 +01:00
Stéphane Adjemian (Charybdis) fac1d206ab Use new wrapper for optimization algorithms when maximizing the prior density. 2015-02-23 18:26:34 +01:00
Stéphane Adjemian (Charybdis) bd39ff34f6 Fixed bug in get_prior_info routine.
lb and ub (lower and upper bounds for the priors) are no more fields of
bayestopt_ structure.
2015-02-23 18:24:57 +01:00
Michel Juillard 2ca7be4e5e Merging changes in master 2015-02-23 18:02:20 +01:00
Stéphane Adjemian (Charybdis) 0ffb9dd6e2 Changed order of the input arguments in dynare_mimimize_objective.
It is more standard to have the name of the routine (defining the
objective to be minimized) as a first argument.
2015-02-23 14:35:41 +01:00
Stéphane Adjemian (Charybdis) beb7826376 Moved optimization related routines in a common subfolder. 2015-02-23 14:26:07 +01:00
Michel Juillard 5fc48440d6 adding global test for identification for sbvar 2015-02-22 22:03:04 +01:00
Michel Juillard 70173d4431 fixing bugs in extended_path 2015-02-22 21:56:42 +01:00
Michel Juillard c4c31fade9 adding global test for identification for sbvar 2015-02-22 21:54:39 +01:00
Stéphane Adjemian (Charybdis) 5865d46a74 Fixed bug. Wrong number of returned arguments when calling
dynare_minimize_objective (missing options_).
2015-02-21 18:14:15 +01:00
Stéphane Adjemian 32c29fece5 Merge pull request #842 from JohannesPfeifer/cosmetics
Cosmetical changes and additional documentation
2015-02-21 15:42:51 +01:00
Stéphane Adjemian (Charybdis) 7df3856cbf Fixed homotopy with bytecode for perfect foresight models. 2015-02-21 13:59:53 +01:00
Stéphane Adjemian (Charybdis) 43f2ec1d9d Fixed display of the homotopy steps when the residuals are complex. 2015-02-21 13:58:52 +01:00
Stéphane Adjemian (Charybdis) ff7c1f5cda Cosmetic change. 2015-02-21 13:57:48 +01:00
Stéphane Adjemian (Charybdis) 9bdf75a52c Fixed bug in the initialization of the homotopy for perfect foresight models. 2015-02-21 13:56:11 +01:00
Stéphane Adjemian (Charybdis) 402a826300 Updated dates submodule. 2015-02-20 15:16:20 +01:00
Stéphane Adjemian (Charybdis) 38b548c4d0 Fixed licence header. 2015-02-20 14:48:25 +01:00
Stéphane Adjemian (Charybdis) d19592f761 Fixed homotopy for perfect foresight models with block option, cosmetic changes. 2015-02-20 14:48:25 +01:00
Sébastien Villemot 1faf755d56 Oops, fixing dseries branch. 2015-02-19 18:26:49 +01:00
Sébastien Villemot e2d7b8ad25 Update dseries. 2015-02-19 18:23:39 +01:00
Michel Juillard 55ea2100c6 Merge branch 'master' into new_ep 2015-02-19 10:27:15 +01:00
Stéphane Adjemian (Charybdis) 5768acf17e Fixed the verbosity of perfect foresight models solvers.
With stack_solve_algo={0, 6} the verbosity is controlled with
options_.verbosity instead of options_.no_homotopy.

Also harmonized the printed informations across these two algorithms.
2015-02-18 23:58:37 +01:00
Stéphane Adjemian (Charybdis) fd0a172637 Remove small imaginary parts in the solution path for perfect foresight
models obtained with stack_solve_algo=7.

Also return oo_.deterministic_simulation.status equal to false if the
solution path is not real.
2015-02-18 23:53:55 +01:00
Stéphane Adjemian (Charybdis) 0851d277c4 Use correct tolerance parameter when solving perfect foresight model
with stack_solve_algo=7.
2015-02-18 23:52:17 +01:00
Stéphane Adjemian (Charybdis) 01b83d767a Added a matlab routine that prints a line by replicating a symbol. 2015-02-18 18:31:39 +01:00
Stéphane Adjemian (Charybdis) 51a277424d Cosmetic changes. 2015-02-18 18:21:45 +01:00
Houtan Bastani 6f0584fe38 fix copyright dates 2015-02-18 03:06:33 +01:00
Stéphane Adjemian (Charybdis) 1c8e1ab913 Merge branch 'remove-globals-from-blocks' 2015-02-17 13:01:17 +01:00
Stéphane Adjemian (Charybdis) cc94ed63b0 Revert "Temporary fix for perfect foresight model simulation with block option."
This reverts commit 8875dbdaa5.
2015-02-17 13:01:01 +01:00
Stéphane Adjemian (Charybdis) a894357655 Removed options_ and oo_ globals from *all* generated dynamic model
routines (with block option) and adapted some routines to reflect this change.
2015-02-17 12:57:30 +01:00
Michel Juillard 83c68c0477 Allowing for models without exogenous variable 2015-02-16 21:30:34 +01:00
Stéphane Adjemian (Charybdis) 8875dbdaa5 Temporary fix for perfect foresight model simulation with block option. 2015-02-16 17:05:37 +01:00
Stéphane Adjemian (Charybdis) d3275db830 Removed options_ and oo_ globals from generated dynamic model
routines (with block option).
2015-02-16 16:56:17 +01:00
Houtan Bastani 333f87ced2 fix headers 2015-02-16 09:08:26 +01:00
Houtan Bastani ca83397d95 update copyright dates for files changed in 2015 2015-02-16 09:08:02 +01:00
Michel Juillard dfc89df6a8 added make_ex_ to fix bug in dyn_forecast and fixed length of output 2015-02-15 17:49:01 +01:00
Michel Juillard f8af7724bb small fixes to perfect foresight 2015-02-15 16:49:33 +01:00
Michel Juillard 6d25d05be4 adapt extended_path to changes in perfect_foresight 2015-02-14 18:29:11 +01:00
Michel Juillard 3c7b1cf2d7 changed calling sequence for sim1; use local variable names without _;
sim1 honors options_.nodisplay
2015-02-14 12:02:18 +01:00
Michel Juillard 21f009a531 Merge branch 'master' into new_ep 2015-02-14 11:54:57 +01:00
Stéphane Adjemian (Charybdis) b3ed7901cf Fixed bug in homotopy for perfect foresight models.
Homotopy was not working if nans or complex numbers were present in oo_.endo_simul.
2015-02-13 16:04:25 +01:00
Stéphane Adjemian (Charybdis) 3b41aa0e60 Fixed bug related to the type of initial_period. 2015-02-13 15:59:49 +01:00
Stéphane Adjemian (Charybdis) ec896d8ca7 Cosmetic changes.
oo_.determinist_simulation.status is a boolean.
2015-02-13 15:58:12 +01:00
Stéphane Adjemian (Charybdis) 59d1c18960 Added routines missing in previous commit. 2015-02-13 10:10:41 +01:00
Stéphane Adjemian (Charybdis) 67be25d1a8 Rewrote homotopy for perfect foresight models. 2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) f40fcb9724 Do not print anything if homotopy (perfect forsight models solver). 2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) bcc68ff15c Updated dseries submodule and dynare_config().
Routines used for loading data are now located in the dseries submodule.
2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) a44e240153 Removed routines for loading data (dynare/matlab folder). 2015-02-12 15:30:27 +01:00
Houtan Bastani a2bd920d6f Workaround for #755
(cherry picked from commit 9a3cca2a55d57c3148fbcfd892a67a1d9731e9b1)

Conflicts:
	matlab/load_csv_file_data.m
2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) 93966f2087 Set verbosity to 0 if homotopy is used to solve the perfect foresight model. 2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) 751e518811 Removed global variables in perfect foresight routines. 2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) 892e6818ed Put argument checks in another routine. 2015-02-12 15:30:27 +01:00
Stéphane Adjemian (Charybdis) 6f7fed2046 Moved sim1* routines in subfolder. 2015-02-12 15:30:26 +01:00
Stéphane Adjemian (Charybdis) 1b55975231 Moved det_cond_forecast routine in subfolder. 2015-02-12 15:30:26 +01:00
Stéphane Adjemian (Charybdis) e4f4a03798 Removed useless routine. 2015-02-12 15:30:26 +01:00
Stéphane Adjemian (Charybdis) df4ee4b983 Moved files related to perfect foresight models in a subfolder. 2015-02-12 15:30:26 +01:00
Michel Juillard 9f7c1a9bc6 fixes to extended path 2015-02-11 22:23:21 +01:00
Johannes Pfeifer 8320a39e61 Add check whether steady state file during estimation overwrittes parameters to be estimated.
This might lead to wrong results and should be checked for.
2015-02-11 12:58:36 +01:00
Houtan Bastani bdb6a2602e preprocessor: ensure that options_.k_order_solver = 1 when order >= 3, closes #844 2015-02-10 03:39:18 +01:00
Houtan Bastani f72910ae33 fix preprocessor implimentation of filter_algorithm option to estimation. closes #843 2015-02-09 03:20:37 +01:00
Michel Juillard 9c6e219990 new implementation for extended path 2015-02-06 12:36:09 +01:00
Michel Juillard 085ab360cc perfect foresight: making simulation_core into a separate file, perfect_foresight_solver_core.m 2015-02-06 12:35:00 +01:00
Houtan Bastani 8673bcf558 reporting: add titleTruncate option 2015-01-27 09:54:37 +01:00
Johannes Pfeifer 1eabb1f6da Change headers to reflect availability of third order approximation 2015-01-27 08:05:57 +01:00
ferhat 5d9b25d2be In dr_block, debugging information printed out should not be handled with options_.verbosity. Adding an additional optional argument to handle the debugging information 2015-01-21 13:48:25 +01:00
Michel Juillard 73e292df2a merged recent changes to submodule dseries 2015-01-17 12:05:12 +01:00
Michel Juillard 8a52ef599b added a local variable for maximum_lag 2015-01-15 13:55:48 +01:00
Michel Juillard 470fbbe0b2 Fixed bug in deterministic simulations with exogenous variables lagged
by more than one period. Added corresponding test cases.
2015-01-15 11:27:00 +01:00
Stéphane Adjemian (Charybdis) 84cef49584 Fixed bug (oo_ must be replaced by DynareResults). 2015-01-14 11:38:36 +01:00
Michel Juillard 5ff129e52d simplified extended_path.m.
homotopy and  variable sample length should be handled in the solvers.
2015-01-11 21:12:32 +01:00
Michel Juillard da8f702429 removed parfor used for building the Jacobian 2015-01-11 21:12:32 +01:00
Michel Juillard 1b38dc6422 fixing crash in computation of Ramsey steady state 2015-01-11 21:12:32 +01:00
Michel Juillard 4179e25e11 fixing bug when lags are greater than one period 2015-01-11 21:12:32 +01:00
Houtan Bastani 060288a777 reporting: run compilation in batchmode to speed it up slightly 2015-01-08 18:37:44 +01:00
Houtan Bastani 14cedf576a reporting: add option to stop LaTeX compilation when an error is encountered (instead of prompting the user for input) 2015-01-08 18:35:10 +01:00
Stéphane Adjemian (Charybdis) 647d7b9761 Do not detrend the data (nonlinear filters). 2015-01-07 16:27:41 +01:00
Houtan Bastani beb3fd1534 reporting: add legendAt option. closes #810 2014-12-29 22:18:08 +01:00
Houtan Bastani 544e10fc29 reporting: fix legend entry for bar graphs 2014-12-29 20:37:44 +01:00
Houtan Bastani 0fbf99232d reporting: add support for bar graphs, closes #809 2014-12-23 17:52:40 +01:00
Houtan Bastani 1b8a58fe5b reporting: fix error message 2014-12-23 17:52:17 +01:00
ferhat 823477519c Corrects the extended path when bytecode option is used 2014-12-19 14:53:23 +01:00
Stéphane Adjemian 077654fda2 Merge pull request #818 from JohannesPfeifer/smoother_only
Various fixes when running only smoother on a model
2014-12-17 11:29:05 +01:00
Houtan Bastani deba05ccc2 Merge pull request #826 from JohannesPfeifer/oo_recursive_
Make dynare_estimation.m return oo_recursive_
2014-12-17 11:02:54 +01:00
ferhat 24b2993f50 Solves issues in deterministic simulation:
- replaces maximum_endo_(lead|lag) by maximum_(lead|lag) to determine the maximum number of lead and lag in deterministic simulation
- allows to use bytecode in solve_perfect_foresight_model.m
- Adds model information in bytecode
2014-12-17 09:37:43 +01:00
Johannes Pfeifer ff8eaf57ad Make dynare_estimation.m return oo_recursive_ 2014-12-15 22:50:38 +01:00
Stéphane Adjemian (Charybdis) f195fade13 Updated particles submodule. 2014-12-15 15:53:40 +01:00
Stéphane Adjemian (Charybdis) 1927f6181f Updated particles module.
This commit breaks the codes except for sequential importance particle filter.
2014-12-12 17:57:58 +01:00
Stéphane Adjemian (Charybdis) 092455419b Merge branch 'master' into rewrite-nonlinear-filters
Conflicts:
	.gitmodules
	matlab/particle/online_auxiliary_filter.m
	matlab/particle/solve_model_for_online_filter.m
2014-12-12 16:22:06 +01:00
Johannes Pfeifer ed8b47bbf4 Add info to header about additional output argument 2014-12-11 20:59:31 +01:00
Johannes Pfeifer c7153ba2ea Add initialization of bounds if estim_params is empty 2014-12-08 11:29:15 +01:00
Johannes Pfeifer dc7cfd3f0d Adjust smoother to data now being a column vector 2014-12-08 11:28:46 +01:00
Johannes Pfeifer bda19832cd Integrate error from negative steady state with loglinear model into print_info.m
Prevents crashes during estimation. Instead of directly crashing, error handling is done via print_info.m so that penalizing the error during estimation is possible
2014-12-04 20:04:36 +01:00
Johannes Pfeifer dd6f8c182c Move call to optimizers in mode-computing to separate file to allow other function to access all integrated optimizers
- also moves several options to subfields of options structure
- allows setting options of newrat
- requires newrat to have compatible kalman_algo specified in order for it to not change options_
- explicitly disallows using analytical derivation with numerical gradient (before the numerical gradient request was overwritten)
- always outputs hessian returned by optimizer (empty matrix if not computed) and deletes subsequent overwriting if cova_compute=0
2014-12-04 19:36:12 +01:00
Stéphane Adjemian (Charybdis) 811877aa6c Switched back on old-oop-style branch and updated submodules dseries and dates.
Note that master branch will not work with Octave (3.8 or 4.0)
because we use the new syntax for classes in the master branch.
2014-12-04 15:53:21 +01:00
Sébastien Villemot 22d1c45dad Update dseries submodule. 2014-12-04 14:46:39 +01:00
Sébastien Villemot fa4e50499d Update dates and dseries submodules. 2014-12-04 14:19:50 +01:00
Johannes Pfeifer e4745cbc65 Add missing abs to unit root check in model_diagnostics.m 2014-12-03 13:35:06 +01:00
Stéphane Adjemian (Charybdis) 7764d07343 Updated date submodule. 2014-12-01 17:35:09 +01:00
Stéphane Adjemian (Charybdis) e2dd9b2526 Updated unit tests submodule. 2014-12-01 17:20:44 +01:00
Stéphane Adjemian (Charybdis) a3c139cb38 Updated dynare_config routine. 2014-11-28 18:35:19 +01:00
Stéphane Adjemian (Charybdis) d1966dbc76 Added dseries class as a submodule. 2014-11-28 18:34:01 +01:00
Stéphane Adjemian (Charybdis) 686289cd01 Updated dynare_config routine. 2014-11-28 18:26:42 +01:00
Stéphane Adjemian (Charybdis) 4d669a4312 Removed matlab/@dseries and utilities/dseries subfolders. 2014-11-28 18:24:05 +01:00
Stéphane Adjemian (Charybdis) bc90d1d6da Merge branch 'remove-@dates' 2014-11-28 18:13:46 +01:00
Stéphane Adjemian (Charybdis) fc3e1b2108 Merge remote-tracking branch 'fred@github/master'
Conflicts:
	matlab/initial_estimation_checks.m
	matlab/utilities/tests
2014-11-28 16:53:44 +01:00
Stéphane Adjemian (Charybdis) 593adcd5e9 Updated dynare_config routine (new path for the dates class and related routines). 2014-11-27 23:19:53 +01:00
Stéphane Adjemian (Charybdis) 6d30ac71d8 Added dates class as a submodule.
The submodule dates is in matlab/modules/ subfolder.
2014-11-27 23:15:18 +01:00
Stéphane Adjemian (Charybdis) a00f026f54 Removed matlab/@dates (class for dates) and matlab/utilities/dates folders. 2014-11-27 22:52:10 +01:00
Marco Ratto 800fd59cf0 Prune no longer used titles and file names 2014-11-27 11:32:03 +01:00
Marco Ratto 1b615b4f70 Bug fix for different behaviour of linspace in older MATLAB varsions (crashed in MATLAB R2011). 2014-11-27 11:30:10 +01:00
Johannes Pfeifer da691bb21c Fix reading in of initval files from Excel
series_-indicator was not set
2014-11-27 10:44:21 +01:00
Johannes Pfeifer 566835bba6 Check size of initval-file provided values and issue more explicit error message 2014-11-27 09:09:30 +01:00
Johannes Pfeifer 6d7c8ef963 Allow reading in of row vectors in initval file 2014-11-27 09:08:57 +01:00
Stéphane Adjemian 6aa7c038ef Merge pull request #799 from JohannesPfeifer/simplex
Further fixes to simplex algorithm related to unset options
2014-11-25 11:45:59 +01:00
Houtan Bastani 97e93941c5 gsa: corrcoef: add missing function from octave forge nan package, #796 2014-11-25 11:25:45 +01:00
Johannes Pfeifer 3d6316bc5e Fix handling of some options in simplex_optimization_routine.m
One was unset, leading to crashes, and the other one was ignored due to naming conflicts
2014-11-25 09:56:14 +01:00
Johannes Pfeifer 268e8627f0 Add missing simple option to global_initialization.m 2014-11-25 09:54:41 +01:00
Houtan Bastani 103788bb5b gsa: add corrcoef from octave forge nan package. closes #796 2014-11-24 17:28:38 +01:00
MichelJuillard 6d12f2141f Merge pull request #765 from JohannesPfeifer/analytic_derivation_message
Fix message in dynare_estimation_init.m
2014-11-21 22:10:30 +01:00
MichelJuillard dc319a973c Merge pull request #768 from JohannesPfeifer/model_diagnostics
Improvements to model diagnostics
2014-11-21 22:09:08 +01:00
MichelJuillard afb60b2528 Merge pull request #767 from JohannesPfeifer/osr_scaling
Fix computation of objective function in OSR when covariances are specified
2014-11-21 22:03:00 +01:00
MichelJuillard 22d4a86c6d Merge pull request #772 from JohannesPfeifer/varexo_det_forecasting
Fix forecasting with exogenous deterministic variables
2014-11-21 21:48:19 +01:00
Houtan Bastani f3f2da54ff load_csv_file: try loading io package before error and expand error message 2014-11-21 16:15:12 +01:00
MichelJuillard 8e9cd95a89 Merge pull request #760 from JohannesPfeifer/fix_smoother
Fix bug when calling non-Bayesian smoother after Bayesian estimation
2014-11-20 10:27:15 +01:00
Houtan Bastani 974ea63b36 Merge pull request #787 from rattoma/gsa
New compact plots for GSA and IRF/moment calibration
2014-11-20 10:20:23 +01:00
Marco Ratto 876635c371 1) Provisions for using mcf_analysis in map_calibration.m
2) Changed synthetic plotting of all restrictions
2014-11-19 19:37:51 +01:00
Marco Ratto a48e053e3a Do not number saved figure when only is saved. 2014-11-19 19:36:27 +01:00
Marco Ratto 3a32d61d32 provisions for using new mcf_analysis.m 2014-11-19 19:35:44 +01:00
Marco Ratto f3c9b39dce Added new Monte Carlo filtering utility, factorizing all Smirnov and correlation tests and plots. 2014-11-19 19:32:07 +01:00
Marco Ratto 6f68ad69a8 Merge remote-tracking branch 'remotes/personal/gsa' into gsa 2014-11-18 15:44:44 +01:00
Marco Ratto 79f68a5f32 1) proper use of new nodecomposition option;
2) bug fix on variable list;
2014-11-18 15:23:26 +01:00
Marco Ratto 3d14c1078e Proper use of nodecomposition option in posterior estimation and identification. 2014-11-18 12:12:22 +01:00
Marco Ratto e3ac15458a Properly deal with dseries in identification. This fixes #781 2014-11-18 11:34:49 +01:00
Houtan Bastani 8d96310436 Merge pull request #702 from rattoma/master
Use the nodecomposition option which is available in th_autocovarianc...
2014-11-17 12:16:43 +01:00
Houtan Bastani c3fdb7517c Merge pull request #782 from JohannesPfeifer/perfect_foresight_message
Cosmetic change to perfect foresight + unit tests
2014-11-17 11:32:07 +01:00
Johannes Pfeifer c5c5caace5 Add utility to convert Dynare 4.5 results structure to 4.4 2014-11-16 21:11:06 +01:00
Johannes Pfeifer cb4fb6aaf1 Replace eval-command in dynare_estimation.m by direct call to fields 2014-11-16 21:11:06 +01:00
Johannes Pfeifer 86cac40362 Harmonize field length for FilteredVariables for calibrated smoother
Analogous to 4f5e0321228c0e4aca19fcd114f26dbaa1bbbfaf
2014-11-16 21:11:06 +01:00
Johannes Pfeifer 4b1e815728 Always display value of posterior/likelihood at the mode
Also clarifies that minus the posterior/likelihood is displayed
2014-11-16 21:11:06 +01:00
Johannes Pfeifer 68b27252d7 Fix selected_variables_only option with classical forecasts
dyn_forecast requires that the smoother has been run on all endogenous variables, leading to crashes. Now, if this option is encountered with classical forecasts, it is overridden. Also documents this in the manual.
2014-11-16 21:08:18 +01:00
Johannes Pfeifer 45ef721d03 Fix computation of SmoothedMeasurementErrors in Bayesian smoother 2014-11-16 21:08:18 +01:00
Johannes Pfeifer 1cbb17f929 Make sure classical filtered variables have the same length as the Bayesian ones, i.e. nobs. 2014-11-16 21:08:18 +01:00
Johannes Pfeifer 49abff9e4d pm3.m: If no TeX names are provided, default to variable names provided
Old default assumes that only moments for endogenous variables considered. This leads to wrong results if e.g. shocks are considered.
2014-11-16 21:08:18 +01:00
Johannes Pfeifer 61253bcb81 Add header with info to pm3.m 2014-11-16 21:08:18 +01:00
Johannes Pfeifer 9f20aaa8e4 Cosmetic fix to wording of error message in resol.m 2014-11-16 21:08:18 +01:00
Johannes Pfeifer b76bc6d79e Make sure all computed moments in Bayesian estimation return column vectors
The HPD were the only exemption, being row vectors.
2014-11-16 21:08:18 +01:00
Johannes Pfeifer 5062f2ec7b Fix length of stored and plotted forecasts for Bayesian estimation
It stored the initial condition(s) in addition to the forecasts for the specified horizon. In plots, the first point was actually not the forecast, but the initial condition. This contrasted with the behavior or ML and recursive Bayesian forecasts. Now the stored and plotted forecasts always have the first forecast horizon as the first entry/data point
2014-11-16 21:08:17 +01:00
Johannes Pfeifer 704f8650af Properly initialize var_yf in forcst.m 2014-11-16 21:08:17 +01:00
Johannes Pfeifer af9e30c658 Change display of failed solution to a warning
Problem can be missed too easily otherwise
2014-11-16 14:35:58 +01:00
Marco Ratto a871441896 1) Forced nodisplay to avoid proliferation of plots;
2) added waitbar;
2014-11-14 18:00:41 +01:00
Marco Ratto 21bf34e609 1) Added new improved plotting utility for Monte Carlo filtering tests: scatter_mcf.m;
2) fixed graphical and printed output for prior stab_map_.m;
3) use corrcoef for pvalue and change default pvalue_corr, alpha2_redform, alpha2_rmse to 1.e-5
2014-11-14 17:59:08 +01:00
Marco Ratto 6a4f79684c Merge remote-tracking branch 'remotes/personal/gsa' into gsa 2014-11-14 17:47:58 +01:00
Marco Ratto 06572f26a4 Use the nodecomposition option which is available in th_autocovariances.m: for large models with the HP filter option, this may spare a lot of time, if only the unconditional moments are needed on output; 2014-11-14 17:28:17 +01:00
Frédéric Karamé 95c3e05f0f Updated particles submodule. 2014-11-14 17:16:55 +01:00
Stéphane Adjemian (Telemachus) aae7c23fe2 Added unitary test for hessian routine. 2014-11-14 16:33:34 +01:00
Johannes Pfeifer ff3c8e94e1 Clean up hessian.m
Fix description of algorithm and document the function better. Also removes manual increasing of loop variable and moves computation of temporary variable not depending on loop variables outside of the loop as it needs to be computed only once.
2014-11-14 16:33:34 +01:00
Jukka Heikkonen 83931dca66 Added legends for the figures. 2014-11-14 14:53:37 +01:00
Jukka Heikkonen 90487c03e0 The naming of the resulting SA restrictions files (Smirnov statistics plots) changed so that the file names shows the endogenous variable and shock name of interest. E.g. If the model file name is ls2003a.mod the file name of the plot may be
ls2003a_prior_irf_calib_y_VS_e_ys_SA_1 showing the endogenous variable name y and shock e_ys.
2014-11-14 14:51:54 +01:00
Houtan Bastani f999f960f8 bug fix: add missing comment 2014-11-14 12:27:20 +01:00
Houtan Bastani b14c10c1a2 Merge pull request #775 from JohannesPfeifer/sim1_imaginary
Take care of imaginary numbers in perfect foresight simulations
2014-11-14 12:24:27 +01:00
Stéphane Adjemian (Telemachus) 2300464cae Merge branch 'simplex' 2014-11-14 11:07:58 +01:00
Michel Juillard 9fa92b0d02 fixing error message 2014-11-14 07:15:24 +01:00
Stéphane Adjemian (Telemachus) a8e7c30e6a Added @dseries/exist method. 2014-11-13 16:53:06 +01:00
Stéphane Adjemian (Telemachus) a473a36526 Updated particles submodule. 2014-11-13 15:56:10 +01:00
Stéphane Adjemian (Telemachus) 5699a4899c Removed local_state_space_iterations_2 routine from particles module. 2014-11-13 15:53:26 +01:00
Stéphane Adjemian (Telemachus) e143f8ef2e Replaced particle folder by a Git submodule (particles). Adapted path in dynare_config. 2014-11-12 17:55:18 +01:00
Johannes Pfeifer cc96d46911 Transfer hard-coded verbosity of simplex algorithm into an option 2014-11-10 19:54:44 +01:00
Johannes Pfeifer 7c59edead2 Make simplex_optimization_routine.m usable outside of estimation
Removes hard-coded parameter names extracted from bayestopt_ by handing them over explicitly
2014-11-10 19:53:55 +01:00
Johannes Pfeifer c3467ddca2 Simplex: return only scalar best value instead of full vector 2014-11-10 19:41:50 +01:00
Stéphane Adjemian (Sedna) bbf6ea50b0 Added workaround for bug in some Matlab versions (wrong type). 2014-11-10 11:21:05 +01:00
Stéphane Adjemian (Telemachus) 0691b08303 Adapated internals routine (name of dynTest routine has changed). 2014-11-09 22:20:43 +01:00
Stéphane Adjemian (Telemachus) 6557849b30 Updated m-unit-tests module. 2014-11-09 22:20:18 +01:00
Stéphane Adjemian (Telemachus) a12e9d684a Force type consistency when comparing actual results and expected
results in unit tests (use logical type).
2014-11-09 22:17:46 +01:00
Stéphane Adjemian (Telemachus) 8fedac4d5e Replaced calls to dyn_assert by calls to dassert.
This routine is used to compare objects i -n unit tests.
2014-11-08 09:28:53 +01:00
Stéphane Adjemian (Telemachus) 479189ef47 Updated path in dynare_config.
For m-unit-tests module.
2014-11-07 22:41:25 +01:00
Stéphane Adjemian (Telemachus) f2aabb1f0d Added m-unit-tests as a submodule. 2014-11-07 22:40:31 +01:00
Stéphane Adjemian 1c62420909 Removed matlab/utilities/tests subfolder. 2014-11-07 22:31:23 +01:00
Houtan Bastani e6789a3707 Merge pull request #761 from JohannesPfeifer/message_test_calibration
Clarify message in test_for_deep_parameters_calibration.m
2014-11-07 17:27:15 +01:00
Houtan Bastani 1f25e7d479 Merge pull request #757 from JohannesPfeifer/fix_display
Add missing run index to looped variable in resol.m
2014-11-07 17:25:50 +01:00
Houtan Bastani a1a0cc098b skipline: simplify code 2014-11-07 16:44:05 +01:00
Houtan Bastani f98a41007e skipline: fix function header 2014-11-07 16:44:05 +01:00
Houtan Bastani ae52f7615c bug fix: skipline 2014-11-07 16:44:05 +01:00
Stéphane Adjemian 6edef09aba Added fake input argument in @dates/isequal. 2014-11-07 16:12:47 +01:00
Stéphane Adjemian d77dec9726 Added optional tolerance parameter in @dseries/isequal method. 2014-11-06 15:43:23 +01:00
Houtan Bastani 884cbc3fbe dseries: bug fix: add delimiter for importdata for .csv files 2014-11-06 14:46:27 +01:00
Houtan Bastani 3f4f348a0a dseries: variable in error messages isn't set 2014-11-06 14:34:05 +01:00
Houtan Bastani 9a966151fa fix typo 2014-11-06 13:48:53 +01:00
Johannes Pfeifer 2a67e2a306 Take care of imaginary numbers in perfect foresight simulations
Finishing with imaginary parts now does not count as a solution and triggers a new homotopy step.
2014-11-06 09:08:50 +01:00
Johannes Pfeifer cb5d3df6a0 Computation of the loss function in the presence of unit root variables was incorrect
Some elements were simply left out. This commit now mimics the computations as in th_autocovariances.m and makes sure the loss function coincides with the one that is obtained by reading out the covariance from oo_.var
2014-11-03 18:05:15 +01:00
Johannes Pfeifer 669016167e Fix bug in osr where moments were not based on optimal parameter draw
M_.params is global and was set by csminwel1 to the last value tested; this does not necessarily coincide with the optimal parameter vector, which may have occurred earlier. This commit explicitly sets the optimal parameter vector.
2014-11-03 18:01:04 +01:00
Johannes Pfeifer 7b1663281b Transform objective function in osr to full matrix
If the objective function only has one element, the scalar product of a sparse matrix and a full matrix is sparse (in contrast to two or more elements). This crashes the osr code subsequently.
2014-11-03 15:29:21 +01:00
Johannes Pfeifer 6bc9b88401 Add reordering of second order derivatives to stochastic_solvers.m
It was erroneously completely moved to dyn_second_order_solver.m in the 4.3 branch when cleaning up dr1.m. Without this reordering, decision rules for exogenous deterministic variables at second order are wrong
2014-11-02 19:34:55 +01:00
MichelJuillard 283912be53 Merge pull request #770 from JohannesPfeifer/Ramsey_aux_vars
Ramsey aux vars
2014-11-02 15:16:44 +01:00
Johannes Pfeifer ecbe428bd7 Fix computation of objective function in OSR if covariances are specified
Due to the preprocessor adding entries for all variable combination into i_var, variables contained in covariances obtained a wrong weighting. By only selecting the unique entries, this cannot happen anymore. Moreover, the computation intensity of the objective does not increase quadratically in the objective anymore.
2014-11-02 12:49:11 +01:00
Michel Juillard 491301c67b th_autocovariances.m creates Gamma_y{nar+2} (variance decomposition)
even if there is a single shock. In that case variance decomposition
is one. It is better if Gamma_y has always the expected
size. disp_th_moments.m only displays variance decomposition if there
is more than one shock.
2014-11-02 11:17:27 +01:00
Michel Juillard fbbe98815b fixing bug introduced in commit 6eb3a3d when displaying theoretical
moments for a model with a single exogenous variable
2014-11-01 09:15:48 +01:00
Johannes Pfeifer c2da796153 Fix distinction between initial values provided to dyn_ramsey_static.m and stale unchanged initial values in oo_.steady_state
In case of no steady state file, they are identical, but with a steady state file, they are not. Moreover, this fixes a problem with the dimension of the input to the steady state file. ys was not initialized and had wrong dimensions
Also adds comments to file.
2014-10-30 13:31:57 +01:00
Johannes Pfeifer 3a9c273535 Allow for check of Hessian at order>2 in model_diagnostics.m 2014-10-29 19:37:03 +01:00
Johannes Pfeifer c1999443ce Condition singularity warning on unit root check
When singularity is detected, try to compute eigenvalues to see if unit root is present and issue warning according to this check
2014-10-29 19:33:33 +01:00
Johannes Pfeifer 8443eb58cd Do not create classical filtered variables at posterior mean if Bayesian filtered variables were requested
The check for running the smoother on the model at the posterior mean is only based on whether the smoother option was set. But filtered_vars is a separate option. If not also checking whether Bayesian filtered variables have already been requested, oo_.FilteredVariables will contain both "ML" and Bayesian fields, which is confusing. The change only saves the filtered variables from the classical smoother if the user did not use Bayesian estimation.
2014-10-29 19:07:49 +01:00
Johannes Pfeifer a159442935 Fix message in dynare_estimation_init.m
If some parameters are NaN after computing the steady state, the message erroneously said that parameters had been changed. In a check for equality, NaN is not equal to NaN. Thus, NaNs are now taken care of separately.
2014-10-29 09:02:29 +01:00
Stéphane Adjemian (Charybdis) 9300a061aa Fixed bug (appearing only with Matlab and legacy data interface) if the m data file is in the current directory.
If the m data file is in the current directory, the first output of
fileparts(options_.datafile) is an empty string. In Matlab the command
cd('') fails, but Octave does not fail in this case (and does nothing).

Added a test on the first output of fileparts, if this output is empty
we do not try to change the current directory.
2014-10-23 11:08:26 +02:00
Stéphane Adjemian (Karaba) 5ab08ed8d3 Added missing semi colon. 2014-10-21 16:37:57 +02:00
Stéphane Adjemian (Karaba) ca28a2b778 Fixed load_m_file_data_legacy.m.
An m file data was not loading if outside the current directory.
2014-10-21 16:05:34 +02:00
Stéphane Adjemian (Karaba) 63d3157267 Do not force the user to provide a clean m data file when using the legacy data interface.
Note that  all the variables  listed in varobs  need to have  the same
number of observations.
2014-10-20 17:28:35 +02:00
Stéphane Adjemian (Karaba) f48566aeae Fixed prior bounds (according to the doc in master branch).
* Second  and  third  positional  arguments  after the  name  of  the
   estimated  parameter   in  the  estimated_params   block  are  only
   considered in the optimization stage (not in the MCMC)

 * Do not  store bounds  in bayestopt_, because  bounds do  not always
   reflect restrictions implied by prior shapes.

 * prior_bounds routine  returns a structure  (with fields lb  and ub)
   instead of a matrix.
2014-10-20 16:18:54 +02:00
Stéphane Adjemian (Karaba) fb14d24036 Do not truncate the plotted prior densities with the truncation
parameters  used   for  optimization  (second   and  third  positional
arguments  after   the  name  of   the  estimated  parameter   in  the
estimated_params block).
2014-10-16 15:27:40 +02:00
Stéphane Adjemian (Karaba) 2d61c39276 Cosmetic changes. 2014-10-16 15:25:51 +02:00
Johannes Pfeifer db2ba6d887 Clarify message in test_for_deep_parameters_calibration.m 2014-10-15 13:42:47 +02:00
Johannes Pfeifer 2c01113e8c Fix bug when calling non-Bayesian smoother after Bayesian estimation
Because xparam1 is used by the smoother, but xparam was set to the posterior mean, the non-Bayesian smoother results were based on the parameters at the mode, which are stored in xparam1.
2014-10-15 09:49:07 +02:00
Stéphane Adjemian (Karaba) d423ae63a8 Set default value for last input argument of lyapunov_symm routine (debug flag). 2014-10-15 09:02:42 +02:00
Johannes Pfeifer 590c0985f8 Add missing run index to looped variable in resol.m 2014-10-13 20:10:57 +02:00
Stéphane Adjemian (Karaba) 935f74883d Added unit tests for lyapunov_symm routine. 2014-10-13 17:42:53 +02:00
Stéphane Adjemian (Karaba) 97b63105a0 Add a parameter to the lyapunov_symm routine (debug mode). 2014-10-13 17:42:53 +02:00
Stéphane Adjemian (Karaba) 55808060cf Removed useless input (complete commit 438a671c3873e5c4e1bb02a54080e930fbc11886). 2014-10-13 17:42:52 +02:00
Johannes Pfeifer b90f3deed2 Bugfixes and improvements related to method 3 of lyapunov_symm.m
- the function was called with the wrong input argument for this case (Q instead of R*Q*R'), crashing with incompatible matrix dimensions
- the persistent variable X was not updated when the size of it changed, leading to crashes when estimation is followed by calls to DsgeSmoother.m where the state-space is different
- Also eliminates the printed output in lyapunov_symm.m that could not be turned off and clutters estimation
2014-10-13 17:42:52 +02:00
Stéphane Adjemian 573d276f1a Merge pull request #739 from JohannesPfeifer/Cosmetic_changes
Cosmetic changes, documentation, and small bugfix
2014-10-13 13:39:19 +02:00
Johannes Pfeifer 96df3b0043 Cosmetic changes to error messages
(cherry picked from commit ffa424d9d88dcd534272b154a3d9848df861914b)
2014-10-13 13:05:46 +02:00
Stéphane Adjemian 78621c03ee Merge pull request #742 from JohannesPfeifer/second_order_hessian_problems
Deal with NaN and Inf in Hessian of dynamic model
2014-10-13 12:49:38 +02:00
Johannes Pfeifer de5875a75b Fix bug still present in CutSample.m
#733 was faulty because it did not account for changes in the first line when more than 1 MH file was present. Now, FirstDraw really denotes the first draw (as opposed to the last draw as before). The subsequent computation of FirstMhFile is then also correct.
2014-10-12 11:33:55 +02:00
Stéphane Adjemian 6c112a2701 Merge pull request #743 from JohannesPfeifer/debug_info_estimation
Add check for NaN parameters to initial_estimation_checks.m
2014-10-10 22:30:12 +02:00
Stéphane Adjemian 06fbf2b2c5 Merge pull request #746 from JohannesPfeifer/rplot
Filter out empty oo_.endo_simul in rplot.m
2014-10-10 22:25:07 +02:00
Stéphane Adjemian (Charybdis) df1e734106 Merge branch 'steady_debug' 2014-10-10 21:47:24 +02:00
Stéphane Adjemian (Charybdis) f4922a8a27 Cosmetic changes. 2014-10-10 21:46:50 +02:00
Stéphane Adjemian 9e3edd6673 Merge pull request #748 from JohannesPfeifer/maxit
Change maxit default value and correct manual
2014-10-10 19:03:56 +02:00
Stéphane Adjemian 37d4cf7e35 Merge pull request #753 from JohannesPfeifer/MCMC_diag
Improve tractability of McMCDiagnostics_core.m by adding header and comm...
2014-10-10 18:46:30 +02:00
Houtan Bastani f4f7a02fd7 Provisions for MATLAB 8.4 (R2014b) 2014-10-10 10:41:04 +02:00
Johannes Pfeifer 1d68ed8da6 Improve tractability of McMCDiagnostics_core.m by adding header and comments. Also uses more intuitive variable names 2014-10-09 10:57:28 +02:00
Johannes Pfeifer 3187c70b97 Add debugging info on initial values for steady state computation 2014-09-30 15:05:12 +02:00
Johannes Pfeifer a9bb341b0a Increase default maxit for steady and deterministic simulations
Judging from forum reports, the default fails too often. Closes #747
2014-09-30 11:47:58 +02:00
Michel Juillard 6bbfa2fa6d removed 1e6 in expression forcing a non-singular Jacobian 2014-09-30 08:13:31 +02:00
Johannes Pfeifer 6a8c968411 Filter out empty oo_.endo_simul in rplot.m 2014-09-29 15:00:45 +02:00
Michel Juillard fa3e77d163 fixing bug in handling options for lmmcp 2014-09-28 10:07:08 +02:00
Johannes Pfeifer 127b7b0221 Add check for NaN parameters to initial_estimation_checks.m
Provides important info to debug cryptic crashes in later routines. Mostly applies to cases where people run estimation without stoch_simul
2014-09-25 09:02:36 +02:00
Johannes Pfeifer b43d52278d Deal with NaN and Inf in Hessian of dynamic model
Checks for these cases in stochastic_solvers.m to prevent cryptic crashes in dll-files later on
2014-09-25 08:49:19 +02:00
Johannes Pfeifer 2d39fc62e2 Make sure the output arguments of dsge_likelihood.m are actually set
Before, trend_coeff and ys were sometimes returned as empty
2014-09-21 11:54:43 +02:00
Johannes Pfeifer 3e427020d6 Cosmetic changes in headers 2014-09-21 11:51:46 +02:00