Description Usage Arguments Details Value See Also
View source: R/nonTransitive.R
This function generates Z random non-transitive dice given the number faces and the corresponding non-transitive probabilities.
1 | nonTransitive.generator(dice, faces, max_value = faces, prob, error = 0.001)
|
dice |
The number Z of non-transitive dice to generate. |
faces |
The number of faces of each die. |
max_value |
The maximum integer allowed as nominal value for the faces. Standard choices are usually |
prob |
The probability one wants the set of dice to be non-transitive. If unspecified, a set of dice with different non-transitive probabilities for each pairing will be generated. |
error |
Computational error to check for machine precision equality. It defaults to 0.001: no need to be specified. |
The function randomly generates sets of dice and stops as soon as a non-transitive set of dice matching the specified conditions is found and only if so. As such, it might happen that it never returns any value, should the condition for non-transitive dice not be matched. One may need to manually interrupt the run (time delay is provided, one could set it as max threshold.)
A data.table
containing the set of non-transitive dice matching the specified conditions.
See also is.nonTransitive
.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.