mean.acomp {compositions} | R Documentation

## Mean amounts and mean compositions

### Description

Compute the mean in the several approaches of compositional and amount data analysis.

### Usage

              ## S3 method for class 'acomp':
              mean(x,...)
              ## S3 method for class 'rcomp':
              mean(x,...)
              ## S3 method for class 'aplus':
              mean(x,...)
              ## S3 method for class 'rplus':
              mean(x,...)
              ## S3 method for class 'rmult':
              mean(x,...,na.action=get(getOption("na.action")))

### Arguments

`x` | a classed dataset of amounts or compositions
`...` | further arguments to `mean` e.g. `trim`
`na.action` | na.action

### Details

The different compositional approaches `acomp`, `rcomp`, `aplus`, `rplus` correpond to different geometries. The mean is calculated in the respective canonical geometry by applying a canonical transform (see `cdt`), taking ordinary `mean.col` and backtransforming.

The Aitchison geometries imply that `mean.acomp` and `mean.aplus` are geometric means, the first one closed. The real geometry implies that `mean.rcomp` and `mean.rplus` are arithmetic means, the first one resulting in a closed composition.

In all cases the mean is again an object of the same class.

### Value

The mean is given as a composition or amount vector of the same class as the original dataset.

### Missing Policy

For the additive scales (rcomp,rplus) the SZ and BDT are treated as zeros and MAR and MNAR as missing information. This is not strictly correct for MNAR.
For relative scales (acomp,aplus), all four types of missings are treated as missing information. This corresponds to the idea that BDT are truncated values (and have the correspoding effect in taking means). For SZ and MAR, only the components in the observed subcomposition are fully relevant. Finally, for MNAR the problem is again that nothing could be done without knowing the MNAR mechanism, so the analysis is limited to taking them as MAR, and being careful with the interpretation. Missing and Below Detecion Limit Policy is explained in more detail in compositions.missing.

### Author(s)

K.Gerald v.d. Boogaart http://www.stat.boogaart.de

### See Also

`clo`, `mean.col`, `geometricmean`, `acomp`, `rcomp`, `aplus`, `rplus`

### Examples

    data(SimulatedAmounts)
    mean.col(sa.lognormals)
    mean(acomp(sa.lognormals))
    mean(rcomp(sa.lognormals))
    mean(aplus(sa.lognormals))
    mean(rplus(sa.lognormals))
    mean(rmult(sa.lognormals))

[Package compositions version 0.91-6 Index]