Hello - I am trying to calculate fiscal multipliers in my model, for which I essentially need to access the underlying data behind the impulse response functions for the relevant fiscal variables.
However I am not entirely sure where this data gets stored, and how I can extract it.
For reference, I am trying to replicate the present value fiscal multiplier - as is the case in page 11 of the attached paper by Leeper, Traum and Walker (Clearing Up the Fiscal Multiplier Morass-Leeper Traum Walker.pdf). It is a pretty standard formula, that features in most fiscal papers; however I am not aware how to get the simulated values of Y, G, R after running the model (in order to calculate the multiplier).
My first instinct was that this information lies beneath the IRF’s after I have run the standard stoch_simul command, but I am not sure how to access it. Alternately, is there something else that I should be looking for in my results?
Thanks a lot. Apologies if this comes across as a very basic question, but can you possibly tell me how to extract this data from the filename_results.mat file.
I am trying to load it, by right-clicking on it; and even by typing the load ( _results.mat) command in the command window. Unfortunately I don’t see anything happen (or am not sure where to look!).
Then you will have the oo_ structure in the workspace, you can visit the content of oo_ from the command line. It’s easy because Matlab provides autocompletion. If you type:
oo_.ir
and TAB+ENTER, Matlab will autocomplete to oo_.irfs and display the content of this field. If you type:
oo_.irfs.
and TAB Matlab will also display the available fields (the name of the IRFs). Then if you want to pick one, do
iirf1 = oo_.irfs.name_of_the_irf
In general it’s better not to use the Matlab GUI and to use the command line instead, or to even better to write a script or a function. What you do in the GUI is not reusable.