gov.sandia.cognition.statistics.method
Class SidakCorrection

java.lang.Object
  extended by gov.sandia.cognition.util.AbstractCloneableSerializable
      extended by gov.sandia.cognition.statistics.method.AbstractMultipleHypothesisComparison<Collection<? extends Number>,StatisticType>
          extended by gov.sandia.cognition.statistics.method.AbstractPairwiseMultipleHypothesisComparison<AdjustedPValueStatistic>
              extended by gov.sandia.cognition.statistics.method.SidakCorrection
All Implemented Interfaces:
MultipleHypothesisComparison<Collection<? extends Number>>, CloneableSerializable, Serializable, Cloneable

@ConfidenceTestAssumptions(name="Sidak correction",
                           alsoKnownAs="Dunn-Sidak correction",
                           description={"Sidak\'s correction is a conservative way to compensate for pair-wise null-hypothesis comparisons applied to multiple comparison to control false-discovery rate.","The correction is known to be overly conservative, trading low false-discovery for high false-negative rates.","The Sidak correction is tighter than the Bonferroni correction, and the Sidak correction is generally preferred."},
                           assumptions={"The assumptions of the underlying pair-wise test are met.","The treatments must be independent."},
                           nullHypothesis="Each treatment has no effect on the measurements of the subjects",
                           dataPaired=true,
                           dataSameSize=true,
                           distribution=AbstractClosedFormSmoothUnivariateDistribution.class,
                           reference={@PublicationReference(author="Janez Demsar",title="Statistical Comparisons of Classifiers over Multiple Data Sets",type=Journal,publication="Journal of Machine Learning Research",year=2006,url="http://www.jmlr.org/papers/volume7/demsar06a/demsar06a.pdf"),@PublicationReference(author="Wikipedia",title="Bonferroni Correction",type=WebPage,year=2011,url="http://en.wikipedia.org/wiki/Bonferroni_correction")})
public class SidakCorrection
extends AbstractPairwiseMultipleHypothesisComparison<AdjustedPValueStatistic>

The Sidak correction takes a pair-wise null-hypothesis test and generalizes it to multiple comparisons by adjusting the requisite p-value to find significance as alpha / NumComparisons. If there are "K" treatments being compared, each treatment is compared to all others: NumComparisons == K*(K-1). The Bonferroni correction is known to be extremely conservative and tightly controls the false-discovery rate.

Since:
3.3.0
Author:
Kevin R. Dixon
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class gov.sandia.cognition.statistics.method.AbstractPairwiseMultipleHypothesisComparison
AbstractPairwiseMultipleHypothesisComparison.Statistic
 
Field Summary
 
Fields inherited from class gov.sandia.cognition.statistics.method.AbstractPairwiseMultipleHypothesisComparison
DEFAULT_PAIRWISE_TEST, pairwiseTest
 
Fields inherited from interface gov.sandia.cognition.statistics.method.MultipleHypothesisComparison
DEFAULT_UNCOMPENSATED_ALPHA
 
Constructor Summary
SidakCorrection()
          Creates a new instance of SidakCorrection
SidakCorrection(NullHypothesisEvaluator<Collection<? extends Number>> pairwiseTest)
          Creates a new instance of SidakCorrection
 
Method Summary
static double adjust(double uncompensatedAlpha, int numComparisons)
          Computes the Sidak multiple-comparison correction
 SidakCorrection clone()
          This makes public the clone method on the Object class and removes the exception that it throws.
 AdjustedPValueStatistic evaluateNullHypotheses(Collection<? extends Collection<? extends Number>> data, double uncompensatedAlpha)
          Evaluates the null hypotheses associated with the given collection of data.
 
Methods inherited from class gov.sandia.cognition.statistics.method.AbstractPairwiseMultipleHypothesisComparison
getPairwiseTest, setPairwiseTest
 
Methods inherited from class gov.sandia.cognition.statistics.method.AbstractMultipleHypothesisComparison
evaluateNullHypotheses
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SidakCorrection

public SidakCorrection()
Creates a new instance of SidakCorrection


SidakCorrection

public SidakCorrection(NullHypothesisEvaluator<Collection<? extends Number>> pairwiseTest)
Creates a new instance of SidakCorrection

Parameters:
pairwiseTest - Confidence test used for pair-wise null-hypothesis tests.
Method Detail

clone

public SidakCorrection clone()
Description copied from class: AbstractCloneableSerializable
This makes public the clone method on the Object class and removes the exception that it throws. Its default behavior is to automatically create a clone of the exact type of object that the clone is called on and to copy all primitives but to keep all references, which means it is a shallow copy. Extensions of this class may want to override this method (but call super.clone() to implement a "smart copy". That is, to target the most common use case for creating a copy of the object. Because of the default behavior being a shallow copy, extending classes only need to handle fields that need to have a deeper copy (or those that need to be reset). Some of the methods in ObjectUtil may be helpful in implementing a custom clone method. Note: The contract of this method is that you must use super.clone() as the basis for your implementation.

Specified by:
clone in interface CloneableSerializable
Overrides:
clone in class AbstractPairwiseMultipleHypothesisComparison<AdjustedPValueStatistic>
Returns:
A clone of this object.

evaluateNullHypotheses

public AdjustedPValueStatistic evaluateNullHypotheses(Collection<? extends Collection<? extends Number>> data,
                                                      double uncompensatedAlpha)
Description copied from interface: MultipleHypothesisComparison
Evaluates the null hypotheses associated with the given collection of data.

Specified by:
evaluateNullHypotheses in interface MultipleHypothesisComparison<Collection<? extends Number>>
Specified by:
evaluateNullHypotheses in class AbstractMultipleHypothesisComparison<Collection<? extends Number>,AdjustedPValueStatistic>
Parameters:
data - Data from each treatment to consider
uncompensatedAlpha - Uncompensated alpha (p-value threshold) for the multiple comparison test, must be [0,1]
Returns:
Statistic that summarizes the multiple comparison test

adjust

public static double adjust(double uncompensatedAlpha,
                            int numComparisons)
Computes the Sidak multiple-comparison correction

Parameters:
uncompensatedAlpha - Uncompensated alpha (p-value threshold) for the multiple comparison test, must be [0,1]
numComparisons - Number of comparisons to make.
Returns:
Sidak correction