Skip to main content

Makes MCMC samples from PyJAGS usable in ArviZ

Project description


Makes MCMC samples from PyJAGS usable in ArviZ

Table of Contents

  1. Installation
  2. Getting Started


  1. Install via PIP:

    pip install pyjags_arviz 


    pip3 install pyjags_arviz 

    if not using Anaconda.

    To get the latest version, clone the repository from github, open a terminal/command prompt, navigate to the root folder and install via

    pip install .


    pip3 install . 

    if not using Anaconda.


Import the function convert_pyjags_samples_dict_to_arviz_inference_data via

from pyjags_arviz import convert_pyjags_samples_dict_to_arviz_inference_data

Having sampled the from the posterior distribution using PyJAGS via

samples \
    = jags_model.sample(...)

one can write

idata = convert_pyjags_samples_dict_to_arviz_inference_data(samples)

to convert the dictionary returned from PyJAGS to an ArviZ InferenceData object.

This object can be used in ArviZ to generate trace plots and compute diagnostics.
Trace plot:


Effective sample size:


Gelman and Rubin statistic:


Project details

Release history Release notifications

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Files for pyjags-arviz, version 0.0.1
Filename, size File type Python version Upload date Hashes
Filename, size pyjags_arviz-0.0.1-py3-none-any.whl (3.1 kB) File type Wheel Python version py3 Upload date Hashes View
Filename, size pyjags_arviz-0.0.1.tar.gz (4.0 kB) File type Source Python version None Upload date Hashes View

Supported by

Pingdom Pingdom Monitoring Google Google Object Storage and Download Analytics Sentry Sentry Error logging AWS AWS Cloud computing DataDog DataDog Monitoring Fastly Fastly CDN DigiCert DigiCert EV certificate StatusPage StatusPage Status page