Skip to content

My implementation of John K. Kruschke's Doing Bayesian Data Analysis 2nd edition using Python and Numpyro.

License

Notifications You must be signed in to change notification settings

beekill95/numpyro-doing-bayesian

Repository files navigation

numpyro-doing-bayesian

My implementation of John K. Kruschke's Doing Bayesian Data Analysis 2nd edition using Python and Numpyro. This implementation is not comprehensive, I'll just focus on the generalized linear model only, which is from chapter 16 onward. Suggestions for improvement are welcome!

Chapters

Dependencies

This project uses a combination of Conda and Poetry for dependencies management. To install the dependencies for this project, make sure that you have conda installed on your system.

First, create a virtual environment managed by conda:

conda env create -f environment.yml

The above command will create a virtual environment named doing_bayes and install poetry package manager into that environment.

After that, activate the environment conda activate doing_bayes and use poetry to install the remaining dependencies:

poetry install

Jupyter Notebook

Activate the doing_bayes environment, and then start the jupyter-lab server:

jupyter-lab --no-browser

Then, you can click on the link to open notebooks on your browsers.

Each chapter's notebook are a normal python script thanks to Jupytext. To generate a notebook for a chapter from the python script, you can follow this instruction.

Credits

My implementation refers to JWarmenhoven's implementation a lot, especially those figures with data and posterior predictive distributions.

About

My implementation of John K. Kruschke's Doing Bayesian Data Analysis 2nd edition using Python and Numpyro.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published