Difference between revisions of "RandomBinomial Command"
From GeoGebra Manual
Line 2: | Line 2: | ||
{{command|probability}} | {{command|probability}} | ||
; RandomBinomial[Number n of Trials, Probability p]: Generates a random number from a binomial distribution with ''n'' trials and probability ''p''. | ; RandomBinomial[Number n of Trials, Probability p]: Generates a random number from a binomial distribution with ''n'' trials and probability ''p''. | ||
+ | :{{example| 1=<div><code><nowiki>RandomBinomial[3, 0.1]</nowiki></code> gives ''i <math>\in</math> {0, 1, 2, 3}'', where the probability of retaining ''i'' is the probability of an event with probability ''0.1'' occuring ''i'' times in three tries. </div>}} | ||
==CAS Syntax== | ==CAS Syntax== | ||
+ | ; RandomBinomial[Number n of Trials, Probability p]: Generates a random number from a binomial distribution with ''n'' trials and probability ''p''. | ||
+ | :{{example| 1=<div><code><nowiki>RandomBinomial[3, 0.1]</nowiki></code> gives ''i <math>\in</math> {0, 1, 2, 3}'', where the probability of retaining ''i'' is the probability of an event with probability ''0.1'' occuring ''i'' times in three tries. </div>}} |
Revision as of 14:26, 3 August 2011
- RandomBinomial[Number n of Trials, Probability p]
- Generates a random number from a binomial distribution with n trials and probability p.
- Example:
RandomBinomial[3, 0.1]
gives i \in {0, 1, 2, 3}, where the probability of retaining i is the probability of an event with probability 0.1 occuring i times in three tries.
CAS Syntax
- RandomBinomial[Number n of Trials, Probability p]
- Generates a random number from a binomial distribution with n trials and probability p.
- Example:
RandomBinomial[3, 0.1]
gives i \in {0, 1, 2, 3}, where the probability of retaining i is the probability of an event with probability 0.1 occuring i times in three tries.