PyMC3 aims for intuitive and readable, yet powerful syntax that reflects how statisticians describe models. The modeling process generally follows these five steps:
- Encode a probability model by defining the following:
- The prior distributions that quantify knowledge and uncertainty about latent variables
- The likelihood function that conditions the parameters on observed data
- Analyze the posterior using one of the options described in the previous section:
- Obtain a point estimate using MAP inference
- Sample from the posterior using MCMC methods
- Approximate the posterior using variational Bayes.
- Check your model using various diagnostic tools.
- Generate predictions.
The resulting model can be used for inference to ...