Last chance! 50% off unlimited learning
Sale ends in
For multivariate outlier detection the Mahalanobis distance can be used. Here a plot of the classical and the robust (based on the MCD) Mahalanobis distance is drawn.
Moutlier(X, quantile = 0.975, plot = TRUE, ...)
Values of the classical Mahalanobis distance
Values of the robust Mahalanobis distance
Value with the outlier cut-off
...
numeric data frame or matrix
cut-off value (quantile) for the Mahalanobis distance
if TRUE a plot is generated
additional graphics parameters, see par
Peter Filzmoser <P.Filzmoser@tuwien.ac.at>
For multivariate normally distributed data, a fraction of 1-quantile of data can be declared as potential multivariate outliers. These would be identified with the Mahalanobis distance based on classical mean and covariance. For deviations from multivariate normality center and covariance have to be estimated in a robust way, e.g. by the MCD estimator. The resulting robust Mahalanobis distance is suitable for outlier detection. Two plots are generated, showing classical and robust Mahalanobis distance versus the observation numbers.
K. Varmuza and P. Filzmoser: Introduction to Multivariate Statistical Analysis in Chemometrics. CRC Press, Boca Raton, FL, 2009.
covMcd
data(glass)
data(glass.grp)
x=glass[,c(2,7)]
require(robustbase)
res <- Moutlier(glass,quantile=0.975,pch=glass.grp)
Run the code above in your browser using DataLab