<< ST_outlier Outlier-Tests Tools >>

samplestat >> samplestat > Outlier-Tests > ST_pearsonhartley

ST_pearsonhartley

Pearson-Hartley outlier test

Syntax

[outlierfree] = ST_pearsonhartley(v, p)
[outlierfree, outlier] = ST_pearsonhartley(v, p)

Arguments

v:

vector of numerical values

p:

statistical confidence level (%) as a string or the level of significance (alpha) as a decimal value, "95%", "99%" or 0.05, 0.01 resp (see examples).

outlierfree:

vector of outlier-free data

outlier:

vector of outliers

Description

Performs the historical, table-based Pearson-Hartley outlier test. It is intended for normally distributed samples with more than 30 values. The historical method is retained here for compatibility with the published Pearson-Hartley table. The test statistic is

\begin{eqnarray}
q=\left| \frac{1}{s}(x_i - \bar{x}) \right| \quad ; \quad q > q_{crit} \quad  \Rightarrow \quad x_i = \text{outlier} \\
x_i: \text{test value} \quad ; \quad \bar{x}: \text{arithmetic mean} \quad ; \quad s: \text{sample standard deviation}
\end{eqnarray}

Use ST_pearsonhartley ONLY with NORMAL distributions.

Use ST_pearsonhartley only for sample sizes greater than 30 and not greater than 1000. For smaller samples use an appropriate small-sample outlier test.

The historical Pearson-Hartley critical-value table is retained unchanged. Its tabulated limits correspond to the historical formulation even though the statistic uses an absolute deviation. For a modern formal test for a single unknown outlier in normally distributed data, ST_grubbs is preferred.

Examples

data = [..
0.21 0.75 0.00 0.33 0.66 0.62 0.84 0.68 0.87 0.06 ..
0.56 0.66 0.72 0.19 0.54 0.23 0.23 0.21 0.88 0.65 ..
0.30 0.93 0.21 0.31 0.36 0.29 0.56 0.48 0.33 0.59 ..
1.23 1.84 0.50 0.43 0.26 0.63 ..
];
of = ST_pearsonhartley(data, "95%")      // outlier-free values
[of, o] = ST_pearsonhartley(data, "95%") // outlier and outlier-free values
[of, o] = ST_pearsonhartley(data, 0.05)  // outlier and outlier-free values

See also

Authors

Bibliography

Lohringer, H., "Pearson-Hartley Outlier Test", Statistics4U, http://www.statistics4u.com/fundstat_eng/ee_pearson_outliertest.html


Report an issue
<< ST_outlier Outlier-Tests Tools >>