bayesplain.priors.BetaPrior

class bayesplain.priors.BetaPrior(a, b, name='custom', rationale='')[source]

A Beta prior over a proportion, carrying its own explanation.

Variables:
b : a,

Shape parameters. Read them as “prior successes” and “prior failures”: Beta(2, 2) behaves like having already seen one success and one failure before the study began.

name : str

Short label used in printed output.

rationale : str

Plain-English statement of what assuming this prior commits you to.

Methods

dist()

Return the prior as a frozen scipy distribution.

a[source]
b[source]
dist()[source]

Return the prior as a frozen scipy distribution.

property label[source]

Name and parameters together, for printing in a summary table.

name = 'custom'[source]
property prior_mean[source]

The rate this prior expects before seeing any data.

property prior_weight[source]

Roughly how many observations of data this prior is worth.

rationale = ''[source]