Running Maximum

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.

Running Maximum

Postby stav » Thu Feb 04, 2016 1:44 pm

Hi,

I have a model where one of the variables is simply the "running maximum" of another, so:

D_t = max(d0,...,dt)

Is it possible to include such a variable with stoch_simul?

Many Thanks
stav
 
Posts: 2
Joined: Wed Jan 27, 2016 1:26 pm

Re: Running Maximum

Postby jpfeifer » Thu Feb 04, 2016 2:19 pm

No, that is not possible, because the max operator will introduce a non-differentiability that will be smoothly approximated.
------------
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: Running Maximum

Postby stav » Fri Feb 05, 2016 8:56 am

Many thanks for your reply.

Would it be any different if I wanted:

D_t = max(d0,...,dt-1)

That is to say, apply the max operator to only historical variables that dynare has already solved for.

What I mean is, I appreciate the dyanre solution approach can never deal with a max within the general model, but is there a way to access stored values and then create, in some sense, a parameter to be applied each period?
stav
 
Posts: 2
Joined: Wed Jan 27, 2016 1:26 pm

Re: Running Maximum

Postby jpfeifer » Sat Feb 20, 2016 9:27 am

No that will not work either, because what you suggest would make the model time-dependent. Decision rules would now depend on the number of previous periods.
------------
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 15 guests