5
\$\begingroup\$

I'm trying to figure out how to implement a dice roller function.

I would like to know the chance in % to get [1 to X] results of 6+ on [1 to 10] 10-sided dice. So, for example, I would like to know the probabilities of 5 10-sided dice resulting in 3 results of 6+ (this is just one set of 10-sided dice I'm curious about).

Thanks a lot for your help.

\$\endgroup\$
1
  • 2
    \$\begingroup\$ So if I understand correctly: you have 10 d10 dice. You would like to know the chance of getting one 6+, and of two 6+, and of three 6+, etc up to the chance of all ten being 6+. Is that correct? \$\endgroup\$ Nov 14, 2018 at 11:34

1 Answer 1

6
\$\begingroup\$

You can use AnyDice, a dice statistic calculator

For your specific use-case, you would put in the script line

output 10d(1d10>6)

And click calculate.

The (1d10>6) represents a single dice roll rolling higher than 6.
The 10d before that repeats the process 10 times and aggregates it, giving a final result of how many times a number of more than 6 was rolled out of 10 dice.

To switch from the probability of exact values to cumulative values (ex. probability of having 1 to \$x\$ values of more than 6), go to the Data control group and select At Least

This will give you the probability of getting 1 to \$x\$ rolls of 6 or more in your dice pool. As seen below, you have an 83.27% chance to have at least 3 dice with results of more than 6 in the pool.

enter image description here

Example AnyDice program used


Note: This tool is tailored for common dice expressions and has a few functions for less common dice processes found in more complex systems. It's not necessarily best suited for other statistical use.

\$\endgroup\$
4
  • \$\begingroup\$ Thanks So has I thought my english isn't very clear in fact it's on a pool of 1 to 10 dices 10... and to know how many chances i've for To get 1x6+ 2x6+ 3x6+ etc in sac roll \$\endgroup\$
    – Jay Whispe
    Nov 14, 2018 at 10:58
  • \$\begingroup\$ @JayWhispe I've replaced the example. \$\endgroup\$
    – Axoren
    Nov 14, 2018 at 11:04
  • 2
    \$\begingroup\$ Shoudn't that be 10d(1d10 > 5) or 10d(1d10 >= 6)? Your current code is counting rolls greater than 6 (i.e. 7 or more). Compare: anydice.com/program/124aa \$\endgroup\$ Nov 15, 2018 at 13:45
  • \$\begingroup\$ @IlmariKaronen Good catch! I can't fix it at the moment, but yes, there is an off-by-one error. \$\endgroup\$
    – Axoren
    Nov 15, 2018 at 22:44

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .