Package com.imsl.stat
Class MultipleComparisons
java.lang.Object
com.imsl.stat.MultipleComparisons
- All Implemented Interfaces:
Serializable,Cloneable
Performs Student-Newman-Keuls multiple comparisons test.
Class MultipleComparisons performs a multiple comparison
analysis of means using the Student-Newman-Keuls method. The null hypothesis
is equality of all possible ordered subsets of a set of means. This null
hypothesis is tested using the Studentized range of each of the
corresponding subsets of sample means. The method is discussed in many
elementary statistics texts, e.g., Kirk (1982, pp. 123-125).
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionMultipleComparisons(double[] means, int df, double stdError) Constructor forMultipleComparisons. -
Method Summary
-
Constructor Details
-
MultipleComparisons
public MultipleComparisons(double[] means, int df, double stdError) Constructor forMultipleComparisons.- Parameters:
means- Adoublearray containing the means.df- Anintscalar containing the degrees of freedom associated withstdError.stdError- Adoublescalar containing the effective estimated standard error of a mean. In fixed effects models,stdErrorequals the estimated standard error of a mean. For example, in a one-way model \({\rm {stdError}} = \sqrt {s^2 / n}\) where \(s^2\) is the estimate of \(\sigma^2\) and n is the number of responses in a sample mean. In models with random components, use \({\rm {stdError}} = {\rm {sedif}} / \sqrt {2}\) wheresedifis the estimated standard error of the difference of two means.
-
-
Method Details
-
compute
public final int[] compute()Performs Student-Newman-Keuls multiple comparisons test.- Returns:
- An
intarray , call itequalMeansindicating the size of the groups of means declared to be equal. ValueequalMeans[I] = Jindicates the I-th smallest mean and the next J-1 larger means are declared equal. ValueequalMeans[I] = 0indicates no group of means starts with the I-th smallest mean.
-
setAlpha
public void setAlpha(double alpha) Sets the significance level of the test- Parameters:
alpha- Adoublescalar containing the significance level of test.alphamust be in the interval [0.01, 0.10]. Default: alpha = 0.01
-