This repository contains example scenarios for estimating the probability of rolling a 1, 2, 3, 4, 5, or 6 for a biased 6-sided die.
The simulation model is defined in die.py and the observation model is defined in roll.py.
Please ensure that nox is installed, and use it (a) simulate die rolls; (b) construct prior samples; (c) fit the model to the simulated die rolls; and (d) plot the results to example.png
:
nox
The solid horizontal lines show the ground truth probability for each outcome, and the dashed horizontal lines show the proportion of simulated die rolls for each outcome.
The code is distributed under the terms of the BSD 3-Clause license (see LICENSE
).