S_TEST
Syntax | Return Value | Arguments | Keywords | Examples | Version History | See Also
The S_TEST function tests the hypothesis that two sample populations X and Y have the same mean of distribution against the hypothesis that they differ.
This routine is written in the IDL language. Its source code can be found in the file s_test.pro in the lib subdirectory of the IDL distribution.
Syntax
Result = S_TEST( X, Y [, ZDIFF=variable] )
Return Value
The result is a two-element vector containing the maximum number of signed differences between corresponding pairs of xi and yi and its one-tailed significance. This type of test is often referred to as the "Sign Test."
Arguments
X
An n-element integer, single-, or double-precision floating-point vector.
Y
An n-element integer, single-, or double-precision floating-point vector.
Keywords
ZDIFF
Set this keyword to a named variable that will contain the number of differences between corresponding pairs of xi and yi resulting in zero. Paired data resulting in a difference of zero are excluded from the ranking and the sample size is correspondingly reduced.
Examples
IDL prints:
The computed probability (0.0729981) is greater than the 0.05 significance level and therefore we do not reject the hypothesis that X and Y have the same mean of distribution.
Version History
See Also
FV_TEST, KW_TEST, MD_TEST, RS_TEST, TM_TEST