Description Usage Arguments Details Value Examples
A function that simulates rolling a pair of fair dice. The goal of the function is to empirically calculate the proportion of times the sum of the dice take on certain numbers, given a specified number of rolls.
1 | proportionofrolls(Rolls = 100, DiceSum = c(3, 10, 11))
|
Rolls |
The number of times you roll the pair of dice |
DiceSum |
A numeric vector, these are possible values for the sum of the dice. Elements of the vector can take any integer value between 2 and 12. The function will calculate the proportion of rolls for which the sum of the dice equals one of the specified integers. |
The output should be the proportion of times the sum of the dice take on any of the values specified in your numeric vector input among the simulated rolls.
a numeric value
1 | proportionofrolls(Rolls=100,DiceSum=c(8,9,10,11,12))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.