Page 1 of 1

Increase number of digits in output

PostPosted: Thu Sep 01, 2016 4:04 pm
by Sophie
Dear all,

I have a very basic question: How can I increase the number of digits shown in the output given by Dynare?
Some of the output is very close to zero and I would like to see more than the four digits shown (for the theoretical moments).
I tried using the matlab-command "format long" before running the file but it did not work...

Thanks for your help

Re: Increase number of digits in output

PostPosted: Thu Sep 01, 2016 5:27 pm
by jpfeifer
That is somewhat tricky. For theoretical moments, you have to go to
Code: Select all
disp_th_moments.m

There you will find calls to dyntable like
Code: Select all
        dyntable(options_,title,headers,labels,z,lh,11,4);

First number at the end is the number of total digits displayed, the last number is the number of decimals. 4 in this case. You need to manually increase it.

Re: Increase number of digits in output

PostPosted: Fri Sep 02, 2016 9:55 am
by Sophie
Thank you very much! It was successful.

Re: Increase number of digits in output

PostPosted: Wed Jun 21, 2017 8:14 pm
by jpfeifer
In
Code: Select all
disp_steady_state.m

the line
Code: Select all
disp(sprintf('%s \t\t %g',endo_names(i,:),steady_state(i)));

needs to be altered from
Code: Select all
%g

to e.g.
Code: Select all
%6g

for six digits