/** * Change the probability of success for this distribution. * * @param p the new probability of success. * @throws IllegalArgumentException if <code>p</code> is not a valid * probability. * @deprecated as of 2.1 (class will become immutable in 3.0) */ @Deprecated public void setProbabilityOfSuccess(double p) { setProbabilityOfSuccessInternal(p); }
/** * Change the probability of success for this distribution. * * @param p the new probability of success. * @throws IllegalArgumentException if <code>p</code> is not a valid * probability. * @deprecated as of 2.1 (class will become immutable in 3.0) */ @Deprecated public void setProbabilityOfSuccess(double p) { setProbabilityOfSuccessInternal(p); } /**
/** * Create a binomial distribution with the given number of trials and * probability of success. * * @param trials the number of trials. * @param p the probability of success. */ public BinomialDistributionImpl(int trials, double p) { super(); setNumberOfTrialsInternal(trials); setProbabilityOfSuccessInternal(p); }
/** * Create a binomial distribution with the given number of trials and * probability of success. * * @param trials the number of trials. * @param p the probability of success. */ public BinomialDistributionImpl(int trials, double p) { super(); setNumberOfTrialsInternal(trials); setProbabilityOfSuccessInternal(p); }