Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

rSDev.test

Relative simplicial deviance tests


Description

Monte Carlo based contingency table tests considering the compositional approach to contingency tables.

Usage

rSDev.test(x, R = 999, method = "multinom")

Arguments

x

matrix, data.frame or table

R

an integer specifying the number of replicates used in the Monte Carlo test.

method

either “rmultinom” (default) or “permutation”.

Details

Method “rmultinom” generate multinomially distributed samples from the independent probability table, which is estimated from x using geometric mean marginals. The relative simplicial deviance of the original data are then compared to the generated ones.

Method “permutation” permutes the entries of x and compares the relative simplicial deviance estimated from the original data to the ones of the permuted data (the independence table is unchanged and originates on x).

Method “rmultinom” should be preferred, while method “permutation” can be used for comparisons.

Value

A list with class “htest” containing the following components:

  • statisticthe value of the relative simplicial deviance (test statistic).

  • methoda character string indicating what type of rSDev.test was performed.

  • p.valuethe p-value for the test.

Author(s)

Matthias Templ, Karel Hron

References

Egozcue, J.J., Pawlowsky-Glahn, V., Templ, M., Hron, K. (2015) Independence in contingency tables using simplicial geometry. Communications in Statistics - Theory and Methods, 44 (18), 3978–3996.

See Also

Examples

data(precipitation)
rSDev.test(precipitation)

robCompositions

Compositional Data Analysis

v2.3.0
GPL (>= 2)
Authors
Matthias Templ [aut, cre] (<https://orcid.org/0000-0002-8638-5276>), Karel Hron [aut] (<https://orcid.org/0000-0002-1847-6598>), Peter Filzmoser [aut] (<https://orcid.org/0000-0002-8014-4682>), Kamila Facevicova [ctb], Petra Kynclova [ctb], Jan Walach [ctb], Veronika Pintar [ctb], Jiajia Chen [ctb], Dominika Miksova [ctb], Bernhard Meindl [ctb], Alessandra Menafoglio [ctb] (<https://orcid.org/0000-0003-0682-6412>), Alessia Di Blasi [ctb], Federico Pavone [ctb], Gianluca Zeni [ctb]
Initial release
2020-11-18

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.