I am trying to optimize welfare for a set of parameters in dynare.
I would like to run the dyname .m file with a function statement, which would have as output the Welfare index.
Apparently dynare does not execute within the function. Is there a trick to remedy this, to get dynare to run within a matlab function statement?
My procedure is to change a parameter, insert it into "load_initial_values" matrix in the dynare program, then execute the dynare .m file,
and then compute welfare. I have a series of optimization functions (simulated annealing and the genetic algorithm) which I would like to use.
Thanks, Paul McNelis