CLR: Centred logratios

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

Computation of centred logratios (CLRs).

Usage

1
CLR(data, weight=TRUE)

Arguments

data

A compositional data frame or matrix

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.

Details

The function CLR computes the set of centred logratios (CLRs).

Value

LR

The centred logratios (CLRs)

LR.wt

The weights assigned to the CLRs

Author(s)

Michael Greenacre

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

invCLR, ALR, invALR, LR, LR.VAR

Examples

1
2

Example output

Loading required package: ca
Loading required package: vegan
Loading required package: permute
Loading required package: lattice
This is vegan 2.5-7
Loading required package: ellipse

Attaching package:ellipseThe following object is masked frompackage:graphics:

    pairs

$LR
                     Protein Carbohydrate        Fat
Asparagus        -0.24819728   0.28979386 -2.6374369
Beans(soya)       0.14485529  -0.01382406 -0.4997849
Broccoli          0.17322105   0.06692447 -1.6933576
Carrots          -1.55409292   0.77833154 -2.9096507
Corn             -1.34037847   0.68390328 -2.6750262
Mushrooms        -1.00958947   0.51726975 -2.0430302
Onions           -1.36366907   0.77493107 -3.7606069
Peas             -0.54514041   0.43545508 -3.1532674
Potatoes(boiled) -1.56393486   0.89534869 -4.3997025
Spinach          -0.06039995   0.17797463 -2.0525896

$LR.wt
     Protein Carbohydrate          Fat 
     0.24974      0.69716      0.05310 

easyCODA documentation built on Jan. 15, 2022, 3 a.m.