Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Check, finalize, and tweak the baseline tables #165

Open
1 of 10 tasks
jlperla opened this issue May 25, 2023 · 0 comments
Open
1 of 10 tasks

Check, finalize, and tweak the baseline tables #165

jlperla opened this issue May 25, 2023 · 0 comments
Assignees

Comments

@jlperla
Copy link
Member

jlperla commented May 25, 2023

@donskerclass you can now generate the baseline tables with python scripts/generate_paper_results/baseline_tables.py

The content is there but I didn't test out its insertion in latex/etc. Unlike the previous examples this will extract as much as possible from the underlying result.json file for a run.

However, there are a few places worth pointing out where things had to be hardcoded around dynare:

  1. https://github.com/HighDimensionalEconLab/HMCExamples.jl/blob/main/scripts/run_dynare_samplers/convert_dynare_output.jl#L75-L76 in the convert_dynare_output.jl sets the T value and the mh_drop. This drop is realted to the Mapping dynare samplers to parameters/etc. for tables #163 issue since my read was we would have to manually apply that drop here and the one in dynare's file only applied to its own statistics. Regardless, we can change those as required.
  2. pseudotrues are hardcoded in https://github.com/HighDimensionalEconLab/HMCExamples.jl/blob/main/scripts/generate_paper_results/baseline_tables.py#L72-L74
  3. the number of particles is hardcoded in https://github.com/HighDimensionalEconLab/HMCExamples.jl/blob/main/scripts/generate_paper_results/baseline_tables.py#L83-L84 Though I suppose we could throw them in the result.json in the dynare step if we really wanted to. Lets leave it here for now then unless you disagree.
    Otherwise things are generally going to extract the values directly from the json and you can refer to them with formatted strings.

For those, the table caption and the footnote can refer to these using the standard python { } . In the case of the footnote it uses a r" which is necessary due to latex braces. But the caption this also works (see the {T} in https://github.com/HighDimensionalEconLab/HMCExamples.jl/blob/main/scripts/generate_paper_results/baseline_tables.py#L95 the list of variables you have access to is: https://github.com/HighDimensionalEconLab/HMCExamples.jl/blob/main/scripts/generate_paper_results/baseline_tables.py#L77

Otherwise this is hopefully pretty clean and flexible. Some of the key todo here (assuming that #163 is done which makes things directly comparable):

  • You will need to run the latest julia --project scripts/run_dynare_samplers/convert_dynare_output.jl on the downloaded stuff
  • Change the captions, which is the second argument to generate_sumstats_table. I think I left most of them as is but through in ther T= {T} for the longer run there.
  • Make sure you like the footnotes
  • Make sure these things actually work in latex. Might be some simple tweaks to the latex formatting/etc. to get them to work.
  • Verify the number of particles are what you want for those dynare exmaples.
  • Verify the pseudotrues for SGU
  • Verify the pseudotrues for RBC
  • From James: Double-check that the Dynare SGU sumstats variable order matches the Julia SGU variable order. Sometimes this wasn't the case.
  • Right now this is standardizing the caption to simply be the name of the underlying run, which makes things less error prone. If you really want to change that then I added in the option to do so by passing in the caption argument. Otherwise I think it makes sense to use that standard in the latex document and just change those captions as well. Makes things very clear when looking for typos there.
  • General code check for inconsistencies and errors.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants