Log data density [Laplace approximation] is NaN.

This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location where you will have to reset your password.
Forum rules
This forum is closed. You can read the posts but cannot write. We have migrated the forum to a new location (https://forum.dynare.org) where you will have to reset your password.

Log data density [Laplace approximation] is NaN.

Postby xusherry » Fri Jul 29, 2016 3:19 am

Dear all:
when i use bayesian esimation method to estimate some parameters using quartly data, and i get errors following that:
Log data density [Laplace approximation] is NaN.

错误使用 chol
矩阵必须为正定矩阵。

出错 metropolis_hastings_initialization (line 68)
d = chol(vv);

出错 random_walk_metropolis_hastings (line 62)
[ ix2, ilogpo2, ModelName, MetropolisFolder, fblck, fline, npar, nblck,
nruns, NewFile, MAX_nruns, d ] = ...

出错 dynare_estimation_1 (line 782)
feval(options_.posterior_sampling_method,objective_function,options_.proposal_distribution,xparam1,invhess,bounds,dataset_,options_,M_,estim_params_,bayestopt_,oo_);

出错 dynare_estimation (line 89)
dynare_estimation_1(var_list,dname);

出错 mypaper (line 650)
dynare_estimation(var_list_);

出错 dynare (line 180)
evalin('base',fname) ;

I don't know how to solve, what is the problem?
I wonder whether is the data problem, and the procedure i handle the data following that:(1)seasonal adjustment to get the trending and cyclic data;(2) then use the logarithmic form for the data;(3) use hp filtering to get the cyclic data, is the procedure right?
And the last question is how to judge the bayesian estimation results or how to judge the model is good or bad?
Hope for your help, thank you!!
Attachments
mypaper.zip
(6.99 KiB) Downloaded 109 times
xusherry
 
Posts: 11
Joined: Sat Jul 02, 2016 2:10 pm

Re: Log data density [Laplace approximation] is NaN.

Postby jpfeifer » Mon Aug 01, 2016 7:09 am

1. You are still not supposed to use an HP-filter for model estimation via ML/Bayesian techniques. See Pfeifer(2013): "A Guide to Specifying Observation Equations for the Estimation of DSGE Models" https://sites.google.com/site/pfeiferecon/Pfeifer_2013_Observation_Equations.pdf

2. The mode_check plots clearly show you the problem. The estimate for alpha_gc is at the boundary of the parameter range allowed by the prior. No interior maximum has been attained. You might want to try a more informative prior.
------------
Johannes Pfeifer
University of Cologne
https://sites.google.com/site/pfeiferecon/
jpfeifer
 
Posts: 6940
Joined: Sun Feb 21, 2010 4:02 pm
Location: Cologne, Germany


Return to Dynare help

Who is online

Users browsing this forum: Google [Bot] and 9 guests