mahaout {dprep} | R Documentation |
This function finds multivariate outliers by constructing a boxplot of the Mahalanobis distance of all the instances.
mahaout(data, nclass, plot = TRUE)
data |
Name of the dataset |
nclass |
Number of the class to check for outliers |
plot |
Logical value. If plot=T a plot of the mahalanobis distance is drawn |
uses cov.rob function from the MASS library
Returns a list of top outliers according to their Mahalanobis distance and a list of
all the instances ordered according to their Mahalanobis distance.
If Plot=T, a plot of the instances ranked by their Mahalanobis distance is provided.
Edgar Acuna
Rousseeuw, P, and Leroy, A. (1987). Robust Regression and outlier detection. John Wiley & Sons. New York.
#---- Detecting outliers using the Mahalanobis distance---- data(bupa) mahaout(bupa,1)