Description Usage Arguments Value
Compute probability of observations across many potential vectors This will try (1/stepsize)^nflips possible vectors, computing the probability of the observation for each
1 2 3 4 5 6 7 8 | try_many_vectors(
nheads,
nflips,
number_samples = 1000,
stopval = 1e-05,
log = FALSE,
possibilities = get_possibilities(nheads, nflips)
)
|
nheads |
Number of heads |
nflips |
Total number of flips (heads and tails) |
number_samples |
How many vectors to sample |
stopval |
How large a difference in probability is considered close enough between the flat model and others |
log |
If TRUE return log transformed probabilities. |
possibilities |
All possible sequences of flips that lead to the observed number of heads |
The likelihood of the data (or log likelihood if log=TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.