Skip to content
David Marx edited this page May 24, 2013 · 31 revisions

To learn more about PyMC, please refer to the online user's guide.

PyMC 3

We are in the planning process for the next major version of PyMC. Here is a wiki page of some of our ideas in this regard.

Examples

Basic examples

  • DisasterModel: A changepoint example, with several variations.

  • StraightLineFit: A two-parameter linear regression.

  • WeibullFit: Fitting the parameters of a Weibull distribution.

  • NormalFit: Fitting the parameters of a normal distribution.

  • VonMisesFit: Fitting the parameters of a Von Mises distribution.

  • GelmanBioassay: From section 3.7 of Bayesian Data Analysis by Gelman et al., 2nd ed.

  • CustomStep: An example of a custom step method.

Intermediate and advanced models

For users familiar with BUGS, here are a few examples that are translated directly from BUGS models; the original code is included in each file as a docstring:

  • Koala Koala sighting model (from Link & Barker 2009)

  • Mt Conditional multinomial mark-recapture model (from Link & Barker 2009)

  • Mt2 Unconditional multinomial mark-recapture model (apparently not possible in BUGS)

  • BayesFactor Simple example of Bayes factor calculation

Gaussian process examples

  • Mean: Creates a mean function.

  • Covariance: Creates a covariance function.

  • Realizations: Draws several realizations.

  • Observations: Observes a mean and covariance, then draws several realizations.

  • BasisCov: Creates a covariance from a basis with normally-distributed coefficients.

  • GPMCMC: Creates a PyMC model containing a Gaussian process, and fits it with MCMC.

  • Non-parametric regression: iPython Notebook of NP regression using GP

Links to external examples

Example-bearing threads on mailing list: