Learning probabilities: Beta Distribution

If it does not load, you may have to download the zip file and use "appletviewer beta.html" until appletviewer is fully depreciated.

This applet shows how the parameter in a beta distribution changes as data is received. Each piece of data is either "positive" or "negative".

The x-axis shows the probability of positive, that is each x value represents P(positive)=x. The leftmost point is P(positive)=0, the rightmost point is P(positive)=1. For any value x in the range [0,1] the y-axis shows P(P(positive)=x|observations) which is proportional to P(observations|P(positive)=x), assuming a uniform prior. This can either be intepreted as a probability density function, where the area under the curve has value 1. In this case the value of the top line after a reset is 1.0. Alternatively, it can be seen as a probability distribution when there are (about) 500 points on the x-axis, and the y-value is the probability of that point. In this case the value of the top line after a reset has value 1/500.

When there are only two states (here "positive" and "negative") it is called the Beta distribution. When there are more states it is called the Dirichlet distribution.

Remember copies the top graph onto the "Remembered" graph at the bottom. This is so you can compare a pair of beta distributions.

You can get the source code.


Copyright © David Poole, 2008. This web page and applet are released under a Creative Commons Attribution-Noncommercial-Share Alike license.