Some questions, few answers...

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.

Some questions, few answers...

Postby jonathanb » Mon Jan 25, 2010 4:11 pm

Hello all,
I have some questions where I don't find "the" answer. In some papers, I find "an" answer, but never "the" answer. So in this forum of specialists, I think that there is one good guy able to give me "the" right answer

1/
I would like to know which parameters values Dynare takes into account in order to compute a stoch_simul after an estimation command.
Does Dynare take the calibrated parameters, the results from posterior maximization, or the results from the Bayesian estimation?

2/
I try to use the model_comparison() command but in the log file I see this:
model_comparison:: The user supplied prior distribution over models is improper...
model_comparison:: The distribution is automatically rescaled!

Is it important (I think yes but tell me) ? and if it is, how to specify a "prior distribution over models", practically and theoretically ?

3/
I obtain a Log data density of -282.723580
This result is negative, but is it an important thing ? I mean, if I have -282 with model 1 and -300 with model 2, could I say that model 1 is "better" than model 2 ? or does the log data density always need to be positive in order to compare models ?

Thank u in advance
Jonathan
Last edited by jonathanb on Tue Jan 26, 2010 9:48 am, edited 1 time in total.
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby Blur » Tue Jan 26, 2010 9:09 am

Thank you Jonathan for your questions, it's exactly what i need !!!
Blur
 
Posts: 2
Joined: Tue Jan 26, 2010 8:58 am

Re: Some questions, few answers...

Postby jonathanb » Thu Jan 28, 2010 5:24 pm

Thank u very much. I hope we get some answers...

I have an other question: when I run my model's estimation, with mh_nblocks=1, it's fine. But when I run with mh_nblocks=2, then dynare stops and tell that:

MCMC Diagnostics: Univariate convergence diagnostic, Brooks and Gelman (1998):
??? Error: File: McMCDiagnostics_core.m Line: 36 Column: 8
Functions cannot be indexed using {} or . indexing.

Error in ==> McMCDiagnostics at 100
fout = McMCDiagnostics_core(localVars,1,npar,0);

Error in ==> dynare_estimation_1 at 1055
McMCDiagnostics(options_, estim_params_, M_);

Error in ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});

Error in ==> mymodel at 247
dynare_estimation(var_list_);

Error in ==> dynare at 132
evalin('base',fname) ;

Is someone have any idea how to solve this issue ?

Thank u in advance for your responses.
Jonathan
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby jonathanb » Wed Feb 03, 2010 12:14 am

No one can help me ?
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby AssiaEzzeroug » Wed Feb 03, 2010 7:34 pm

Hi,

1) if the instruction stoch_simul appears after the block estimation, it will be computed from the parameters' estimated value.


2) the error msg u got might be due to the priors associated with each model u wanna compare. Make sure the sum of weights is equal to unity. By default the comparison is based on the Laplace approximation.


3) if ur log density is negative, it means ur likelihood is less than 1, then taking the log give naturally a negative number.
Since you wanna select the model with the higher likelihood, in ur example it means that model 1 'fit better' than model 2..


Regarding the MH block issue, I might need ur mod-file to reproduce the error.. could you post it plz?

Best
AssiaEzzeroug
 
Posts: 83
Joined: Tue Nov 24, 2009 3:48 pm

Re: Some questions, few answers...

Postby jonathanb » Thu Feb 04, 2010 10:48 pm

Thank u very much but your answers are not satisfying me for 2 and 3 :wink:

2/ OK, but how to specify a "prior distribution over models", practically and theoretically? I mean, following your answer, how to specify the "weights" in my .mod file ? What is the signification of these "weights" ?

3/ OK, I know that my likelihood is less than 1, but is it significant ? Is the fact that my likelihood is less than one give me some information about my model?

4/ Concerning the mh_nblocks issue, I enclose the .mod file

5/ I have another question: In "classical" estimations (fiml, gmm, ols ...), we have a determination coefficient (R2), student tests or Akaike criterion for examples, in order to say that our estimation is "good or not". What are the main indicators to look at in bayesian estimations? Are the student tests given by the "POSTERIOR MAXIMISATION" in Dynare bayesian estimation (just before MH iterations) are relevant ?

Thank u very much for all of your past and future answers :D

Sincerly yours
Jonathan
Attachments
model.mod
(2.24 KiB) Downloaded 118 times
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby jonathanb » Tue Feb 09, 2010 9:31 am

I'm sorry, I've forgotten the corresponding datafile
Thanks for all

ps: change the filename in .mat after downloading in the same folder than model.mod (why .mat is not allowed in the forum attachments ?)

Sincerly yours
Jonathan
Attachments
data.m
(4.92 KiB) Downloaded 94 times
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby Blur » Thu Feb 11, 2010 6:16 pm

Have u tried to run your .mod with different prior distributions???
Blur
 
Posts: 2
Joined: Tue Jan 26, 2010 8:58 am

Re: Some questions, few answers...

Postby jonathanb » Mon Feb 15, 2010 6:03 pm

yes, but there is no significant changes...

thank u blur for your help and tell me if you find something or if you can answer to my questions
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York

Re: Some questions, few answers...

Postby StephaneAdjemian » Sat Feb 20, 2010 12:01 am

Hi,

jonathanb wrote:
I try to use the model_comparison() command but in the log file I see this:
model_comparison:: The user supplied prior distribution over models is improper...
model_comparison:: The distribution is automatically rescaled!

Is it important (I think yes but tell me) ? and if it is, how to specify a "prior distribution over models", practically and theoretically ?



This message simply warns you that the sum of probabilities (associated to the different models) does not sum to one. Dynare then rescales the distribution, so that the probabilities add to one. There is a huge statistical literature about the choice of a prior distribution over models. I have no precise reference in mind right now, but if you google model comparison bayesian prior you will find tons of papers about this problem. You can start with a uniform distribution...

Best,
Stéphane.
Stéphane Adjemian
Université du Maine, GAINS and DynareTeam
https://stepan.adjemian.eu
StephaneAdjemian
 
Posts: 429
Joined: Wed Jan 05, 2005 4:24 pm
Location: Paris, France.

Re: Some questions, few answers...

Postby StephaneAdjemian » Sat Feb 20, 2010 12:09 am

Hi,

jonathanb wrote:
I have an other question: when I run my model's estimation, with mh_nblocks=1, it's fine. But when I run with mh_nblocks=2, then dynare stops and tell that:

MCMC Diagnostics: Univariate convergence diagnostic, Brooks and Gelman (1998):
??? Error: File: McMCDiagnostics_core.m Line: 36 Column: 8
Functions cannot be indexed using {} or . indexing.

Error in ==> McMCDiagnostics at 100
fout = McMCDiagnostics_core(localVars,1,npar,0);

Error in ==> dynare_estimation_1 at 1055
McMCDiagnostics(options_, estim_params_, M_);

Error in ==> dynare_estimation at 62
dynare_estimation_1(var_list,varargin{:});

Error in ==> mymodel at 247
dynare_estimation(var_list_);

Error in ==> dynare at 132
evalin('base',fname) ;

Is someone have any idea how to solve this issue ?

Thank u in advance for your responses.
Jonathan


I have already seen this bug. Are you using matlab version 7.0 or an older version ? A quick workaround is to use option nodiagnostics with the estimation command (Dynare won't compute the convergence diagnostics).

Best, Stéphane.
Stéphane Adjemian
Université du Maine, GAINS and DynareTeam
https://stepan.adjemian.eu
StephaneAdjemian
 
Posts: 429
Joined: Wed Jan 05, 2005 4:24 pm
Location: Paris, France.

Re: Some questions, few answers...

Postby jonathanb » Sat Feb 20, 2010 9:46 pm

I use the R2009B 64bits

Thank u very much for your answers.
jonathanb
 
Posts: 54
Joined: Wed Sep 17, 2008 8:52 pm
Location: New York


Return to Dynare help

Who is online

Users browsing this forum: No registered users and 8 guests