Loading initial values from MAT file

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.

Loading initial values from MAT file

Postby cansever » Tue Oct 20, 2015 10:59 pm

Hi folks,
my question is that,
is it possible to LOAD initial values to .mod file from a .mat file ?

I have initialvalues.m containing y and c,
how can I load these to dynare instead of writing manually?

Best regards,
Can.
cansever
 
Posts: 6
Joined: Tue Oct 20, 2015 10:54 pm

Re: Loading initial values from MAT file

Postby jpfeifer » Fri Oct 23, 2015 6:13 am

That is not so easy. The only way I can think of is defining new parameters that store these initial values. Before the model-block, you assign your saved values to the parameters

Code: Select all
load myfile;
y_start=mysavedvaluefory;

initval;
y=y_start;
end;
------------
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

Re: Loading initial values from MAT file

Postby cansever » Wed Dec 30, 2015 12:56 pm

Thanks a lot!
Can
cansever
 
Posts: 6
Joined: Tue Oct 20, 2015 10:54 pm


Return to Dynare help

Who is online

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