-
Notifications
You must be signed in to change notification settings - Fork 0
/
ToDo
25 lines (16 loc) · 1.3 KB
/
ToDo
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/*
Centered planar transform
Compute the centered planar transform of a (dataset of) compositions and its inverse.
Arguments
in a composition or a data.matrix of compositions, not necessarily closed
out the cpt-transform of a composition or a data matrix of cpt-transforms of compositions. It is checked that the z sum up to 0.
The cpt-transform maps a composition in the D-part real-simplex isometrically to a D-1 dimensional euclidian vector space, identified with a plane parallel to the simplex but passing through the origin. However the transformation is not injective and does not even reach the whole plane. Thus resulting covariance matrices are always singular.
The data can then be analysed in this transformed space by all classical multivariate analysis tools not relying on a full rank of the covariance matrix. See ipt and apt for alternatives. The interpretation of the results is relatively easy since the relation of each transformed component to the original parts is preserved.
The centered planar transform is given by
cpt(x)_i = clo(x)_i - 1/D
References
van den Boogaart, K.G. and R. Tolosana-Delgado (2007) "compositions": a unified R package to analyze Compositional Data, Computers & Geosciences. (in press).
*/
void
// ToDo: Inv_clr(in, out Matrix64)
// ToDo: inv_alr(Matrix *in, Matrix *out)