Commit Graph

7963 Commits (da691bb21c6a6855f787c6e2cccd488b5efe25d3)

Author SHA1 Message Date
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 e94056a765 Add unit test for correct computation of loss function in the presence of non-stationary variables 2014-11-03 18:08:30 +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
Houtan Bastani 3e3a0ff06d fix typo 2014-11-03 15:48:21 +01:00
Houtan Bastani a033251140 fix typo 2014-11-03 15:46:58 +01:00
Houtan Bastani 844349c887 update installation instructions for OS X 2014-11-03 15:45:14 +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
Johannes Pfeifer 52935c82dc Fix typo in manual 2014-11-02 19:31:59 +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 4aaebfbe46 Add unit test to check whether objective function matches and whether covariances actually work 2014-11-02 13:15:55 +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
Houtan Bastani d602c0217a update instructions for compilation on os x 2014-10-31 10:48:46 +01:00
Houtan Bastani 0dbff4fa52 build system: modify blas check for os x 10.10 2014-10-30 16:25:01 +01:00
Johannes Pfeifer 3d6af995bc Update unit test by adding also auxiliary variables on exogenous variables 2014-10-30 14:23:13 +01:00
Johannes Pfeifer 38a0941d69 Add unit test file Ramsey with auxiliary variables
TBD: add check for correctness. As variables are dummy variables, the solution should be identical to the one without these auxiliary variables
2014-10-30 13:31:58 +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 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) 7ab86d31ec Dataset factorization. Removed tests/kalman/lyapunov/fsdat_simul.m and use tests/fs2000/fsdat_simul.m instead. 2014-10-21 16:42:52 +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) a06083cb12 Fixed test (new data interface). 2014-10-20 16:31:40 +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
Johannes Pfeifer 83123a59d5 Provide example for xls_range option in manual 2014-10-15 09:45:19 +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
Michel Juillard c8ac7007f0 fixing bug in test case of standalone c++ 2014-10-14 10:25:24 +02:00
Stéphane Adjemian (Charybdis) 8244862bd1 Removed "spurious" characters. 2014-10-13 23:01:40 +02:00
Stéphane Adjemian (Charybdis) 9b3337c94d Oups. I forgot to remove a dependency to a binary in tests/Makefile.am. 2014-10-13 22:21:23 +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) f99fcfa27f Removed "Do pure Lyapunov tests" section.
This should be done in the 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) a9b5fb4263 Fixed test introduced in commit and removed binary file.
Test was introduced in b11d14498aadac17c08b08dd80b6daf7dec9e340.

The binary  file was a mat  file containing a posterior  mode, and the
second estimation must be run iff the control toolbox is available.
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 7605820dff Add unit test for Lyapunov solver
- tests whether they run within a mod-file
- tests whether they yield the same result for a simple state-space model
2014-10-13 17:42:52 +02:00