Package

breeze.stats

hypothesis

Permalink

package hypothesis

This package contains hypothesis tests.

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. hypothesis
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. case class Chi2Result(chi2: Double, pVal: Double) extends Product with Serializable

    Permalink

Value Members

  1. def chi2Test(control: (Long, Long), trials: Seq[(Long, Long)]): Seq[Chi2Result]

    Permalink

    Takes a sequence of N Bernoulli trials, and determines using a chi2 test whether there is a statistically significant difference between the N variants and a control.

    Takes a sequence of N Bernoulli trials, and determines using a chi2 test whether there is a statistically significant difference between the N variants and a control. I.e., the variants may differ from each other, but this only determines whether they differ from control.

    The pVal reported in the results is the probability (assuming the null hypothesis) of a false positive at least this large in *any* variant, not in one particular variant. I.e., multiple comparisons are corrected for.

  2. def chi2Test(successControl: Long, trialsControl: Long, successVariant: Long, trialsVariant: Long): Chi2Result

    Permalink
  3. def sidakCorrectedPVal(p: Double, n: Int): Double

    Permalink

    Takes a p-value run for a single statistical test, and then corrects for multiple comparisons.

    Takes a p-value run for a single statistical test, and then corrects for multiple comparisons.

    I.e., if you run n tests with a p-value cutoff of 5% yielding p-values p1, p2, ..., pn, then if sidakCorrectedPVal(p1,n) < 5% or sidakCorrectedPVal(p2, n) < 5%, etc, you can reject the null hypothesis.

  4. def sidakCorrectedPValCutoff(p: Double, n: Int): Double

    Permalink

    Takes a p-value run for a single statistical test, and then corrects for multiple comparisons.

    Takes a p-value run for a single statistical test, and then corrects for multiple comparisons.

    This function is the inverse of sidakCorrectedPVal. If you run n tests and want a 5% chance of false positive (assuming null hypothesis is true) across *all* tests, then you can run each individual test with a p-value cutoff of sidakCorrectedPValCutoff(0.05, n).

  5. def tTest[X](it1: X)(implicit ct: CanTraverseValues[X, Double]): Double

    Permalink
  6. def tTest[T](it1: Traversable[T])(implicit numeric: Numeric[T]): Double

    Permalink
  7. def tTest[X](it1: X, it2: X)(implicit ct: CanTraverseValues[X, Double]): Double

    Permalink
  8. def tTest[T](it1: TraversableOnce[T], it2: Traversable[T])(implicit numeric: Numeric[T]): Double

    Permalink

    Implements two tailed Welch's T Test (equivalent to t.test in R) Returns a p value

Inherited from AnyRef

Inherited from Any

Ungrouped