Returns tests for multivariate Skewness and kurtosis as well as Mahalanobis' D-squared.

1 |

`x` |
A multivariate data object as in columns from a data.frame |

`s` |
Covariance matrix of x (not necessary to specify) |

`chicrit` |
p-value corresponding to critical value of chi-square distribution for detecting multivariate outliers |

Tests for multivariate skewness and kurtosis were adapted from SAS macros in Khatree & Naik (1999). They attribute the formula to Mardia (1970; 1974). Mahalanobis' Dsq is based on Mahalanobis (1936). Dsq is multivariate analogue to z scores, but based on the chi-sq distribution rather than normal distribution. Once can specify at what level one wishes to define multivariate outliers (e.g., .005, .001)

A list containing the following:

`mult.test ` |
Values for multivariate skeweness and kurtosis and their significance |

`Dsq ` |
Mahalanobis' distances |

`CriticalDsq ` |
Critical value of chi-sq distribution based on df and specified critical level |

Mahalanobis is returned without regard to NAs (missing observations) and is useful only in detecting IF multivariate outliers are present. If one wishes to determine which cases are multivariate outliers and if one has missing observations, `mahalanobis`

is perhaps a better choice.

These statistics are known to be susceptible to sample size (as in their univariate counterparts). One should always use graphical methods such as `qqplot`

in addition to statistical.

Thomas D. Fletcher tom.fletcher.mp7e@statefarm.com

Khattree, R. & Naik, D. N. (1999). *Applied multivariate statistics with SAS software (2nd ed.).* Cary, NC: SAS Institute Inc.

1 2 3 4 5 6 | ```
# assess the multivariate normality of variables 4,5,6 in USJudgeRatings
data(USJudgeRatings)
mn <- mult.norm(USJudgeRatings[,4:6],chicrit=.001)
mn
mn$Dsq > mn$CriticalDsq
``` |

Questions? Problems? Suggestions? Tweet to @rdrrHQ or email at ian@mutexlabs.com.

Please suggest features or report bugs with the GitHub issue tracker.

All documentation is copyright its authors; we didn't write any of that.

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.