Learn R Programming

robCompositions (version 2.0.0)

variation: Robust and classical variation matrix

Description

Estimates the variation matrix with robust methods.

Usage

variation(x, robust = TRUE)

Arguments

x
data frame or matrix with positive entries
robust
if FALSE, standard measures are used.

Value

The (robust) variation matrix.

Details

The variation matrix is estimated for a given compositional data set. Instead of using the classical standard deviations the mad is used when parameter robust is set to TRUE.

References

Aitchison, J. (1986) The Statistical Analysis of Compositional Data Monographs on Statistics and Applied Probability. Chapman \& Hall Ltd., London (UK). 416p.

Examples

Run this code

data(expenditures)
variation(expenditures)
variation(expenditures, robust=FALSE)

Run the code above in your browser using DataLab