Python must be installed as well as the Python packages pandas, numpy, pystan, matplotlib, arviz, sklearn, and scipy
Tested under Python 3.8 and Linux. For Mac, you may need to set the argument
n_jobs to 1 in the function call stan_model.sampling.
You should be able to run the *.py files interactively or by submitting to the
file to the Python interpreter.
Warning: run_model_no_sim_neg_binom_quad.py and
run_model_with_sim_neg_binom_quad.py may take a long time to run, hours, not
minutes.
Troubleshooting: If the call to az.to_netcdf causes an error, upgrade
pystan to the latest PyPI version and upgrade arviz to the latest development
version.
pip install --upgrade pystan
pip uninstall arviz
pip install git+git://github.com/arviz-devs/arviz.git
data/a^_vs_a_image_threshold_v2.xlsxsimulation0.csvsimulation1.csvsimulation2.csvsimulation3.csvsimulation4.csvsimulation5.csvsimulation6.csvsimulation7.csvsimulation8.csvsimulation9.csvsimulation10.csvsimulation11.csv
model/model_no_sim_neg_binom_quad.stanmodel_with_wim_neg_binom_quad.stanrun_model_no_sim_neg_binom_quad.py- input --
a^_vs_a_image_threshold_v2.xlsxandmodel_no_sim_neg_binom_quad.stan - output --
post_samps_no_som_neg_binom_quad.nc
- input --
run_model_with_sim_neg_binom_quad.py- input --
a^_vs_a_image_threshold_v2.xlsx,simulation*.csv, andmodel_with_sim_neg_binom_quad.stan - output --
post_samps_iwth_sim_neg_binom_quad.nc
- input --
manuscript_no_sim_plot_quad.py- input --
a^_vs_a_image_threshold_v2.xlsxandpost_samps_no_sim_neg_binom_quad.nc - output --
no_sim_results_manuscript_neg_binom_quad.pngandno_sim_results_compare_quad.png
- input --
manuscript_with_sim_plot_quad.py- input --
a^_vs_a_image_threshold_v2.xlsx,simulation*.csv,post_samps_with_sim_neg_binom_quad.nc, andpost_samps_no_sim_neg_binom_quad.nc - output --
compare_with_sim_no_sim.pngandpod_compare_with_sim_no_sim.png
- input --