Learn R Programming

compositions (version 1.10-1)

NormalTests: Compositional Goodness of fit test

Description

Tests for several groups of additive lognormally distributed compositions.

Usage

acompNormalLocation.test(x,g=NULL,var.equal=FALSE,paired=FALSE,R=0)
acompNormalSpread.test(x,g=NULL,mean.equal=FALSE)

Arguments

x
a dataset of compositions (acomp) or a list of such
g
a factor grouping the data, not used if x is a list already
var.equal
a boolean telling wether the variance of the groups should be considered equal
mean.equal
a boolean telling wether the mean of the groups should be considered equal
paired
true if a paired test should be performed
R
number of replicates that should be used to compute p-values. 0 means comparing the likelihood statistic with the correponding asymptotic chisq-distribution.

Value

  • A classical "htest" object
  • data.nameThe name of the dataset as specified
  • methoda name for the test used
  • alternativean empty string
  • replicatesa dataset of p-value distributions under the Null-Hypothesis got from nonparametric bootstrap
  • p.valueThe p.value computed for this test

Missing Policy

Up to now the tests can not handle missings.

Details

The tests are based on likelihood ratio statistics.

References

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

See Also

fitDirichlet,rDirichlet, runif.acomp, rnorm.acomp,

Examples

Run this code
x <- runif.acomp(100,4)
y <- runif.acomp(100,4)
acompNormalLocation.test(list(x,y))
acompNormalSpread.test(list(x,y))

Run the code above in your browser using DataLab