- Check the following definition of a probabilistic model. Identify the likelihood, the prior, and the posterior:
![](https://static.packt-cdn.com/products/9781789341652/graphics/assets/03269c04-d9fc-433d-a5bf-732c80e39308.png)
- For the model in exercise 1, how many parameters have the posterior? In other words, how many dimensions does it have?
- Write down Bayes' theorem for the model in exercise 1.
- Check the following model. Identify the linear model and identify the likelihood. How many parameters does the posterior have?
![](https://static.packt-cdn.com/products/9781789341652/graphics/assets/ca9fd4c5-50f5-40cd-a5bc-3320eac00f53.png)
- For the model in exercise 1, assume that you have a dataset with 57 data points coming from a Gaussian with a mean of 4 and a standard deviation of 0.5. Using PyMC3, compute:
- The posterior distribution
- The prior distribution
- The posterior predictive distribution
- The prior predictive distribution
Tip: Besides pm.sample(), PyMC3 has other functions to compute samples.
- Execute model_g using NUTS (the default sampler) and then...