Learn R Programming

easyCODA (version 0.40.2)

ALR: Additive logratios

Description

Computation of additive logratios (ALRs) with respect to a specified part.

Usage

ALR(data, denom=ncol(data), weight=TRUE, stats=FALSE)

Value

LR

The additive logratios (ALRs)

LR.wt

The weights assigned to the ALRs

denom

The index of the denominator used in the computation of the ALRs

part.names

The part names in the data, i.e. column names

part.wt

The part weights

means

The means of the ALRs (only returned if stats = TRUE)

vars

The variances of the ALRs (only returned if stats = TRUE)

totvar

The total variance of the ALRs (only returned if stats = TRUE)

Arguments

data

A compositional data frame or matrix

denom

Number of part used in the denominator

weight

Logical indicating if varying weights are returned(default:TRUE). If FALSE, unweighted (equal) weights are returned. Alternatively a set of positive weights can be specified.

stats

Logical indicating if means, variances and total variance of the ALRs are returned (default:FALSE)

Author

Michael Greenacre

Details

The function ALR computes a set of additive logratios (ALRs) with respect to a specified part (by default, the last part).

References

Aitchison, J. (1986), The Statistical Analysis of Compositional Data, Chapman & Hall.
Greenacre, M. (2018), Compositional Data Analysis in Practice, Chapman & Hall / CRC Press.

See Also

invALR, LR, CLR, invCLR, LR.VAR

Examples

Run this code
data(veg)
ALR(veg, denom=2)

Run the code above in your browser using DataLab