medq: Multivariate Medians and Distance Quantiles

Description Usage Arguments Value References See Also Examples

View source: R/medq.r

Description

The medq command calculates univariate or multivariate medians and distance quantiles either by groups specified by a grouping variable or for the entire data set being used. Options allow you to specify quantiles to report that differ from the default quantiles. This is generally used as descriptive statistics with MRPP analyses and describes the distributional changes detected by MRPP.

Usage

1
2
medq(variables, group, data, save.test = FALSE,
  quant = c(0, 0.05, 0.1, 0.25, 0.5, 0.75, 0.9, 0.95, 1))

Arguments

variables

a vector specifying the names of the variables to be used in the analysis. Any names specified here must be matched by a column name in the argument supplied to data. This is an optional argument and assuming the first column in the data.frame supplied to data is the grouping variable and all others are the responses then the variables need not be explicitly specified.

group

the name of the grouping variable. This should be a column name in the data.frame supplied to the data argument. This is optional as described above.

data

a data.frame with either the first column representing the grouping variable and all other columns being response variables or a data.frame with names matching those supplied in the variables and group arguments described above.

save.test

stores the distance between each observation and its group bivariate median these can be later extracted using the command Dist2mvm.

quant

a vector of quantiles for which multivariate quantiles should be calculated.

Value

medq returns an object of class MEDQObj.

References

Mielke, P.W., Jr. and Berry, K.J. 2001. Permutation methods: A distance function approach. Springer-Verlag.

See Also

Dist2mvm and mrpp

Examples

1
2
3
4
5
6
out <- medq(data = bgrouse)
summary(out)

BgDist2mvm <- Dist2mvm(out)

medq(c(distance,elev),sex,data = bgrouse,quant = c(.2,.3,.4))

Blossom documentation built on May 29, 2017, 10:55 p.m.

Related to medq in Blossom...