View source: R/ObtainigValuePB.R
ObtainigValuePB | R Documentation |
Calculates the value of the principal balances (Martín-Fernández et al, 2018) at all time points.
ObtainigValuePB(Num, Dem, especie, Tt)
Num |
List. The component i of the list has the number of the row of the matrix |
Dem |
List. The component i of the list has the number of the row of the matrix |
especie |
Matrix that contains at row i the bacterial taxa of bacteria i at all time points. |
Tt |
Number of time points available |
Returns a matrix where the row i has the value of the principal balance at all time points. The principal balance of the row i has at its numerator the bacteria placed in the rows Num[[i]]
of the especie
. The principal balance of the row i has at its denominator the bacteria placed in the rows Dem[[i]]
of the especie
.
Creus-Martí, I., Moya, A., Santonja, F. J. (2022). Bayesian hierarchical compositional models for analysing longitudinal abundance data from microbiome studies. Complexity, 2022.
Martín-Fernández, J. A., Pawlowsky-Glahn, V., Egozcue, J. J., & Tolosona-Delgado, R. (2018). Advances in principal balances for compositional data. Mathematical Geosciences, 50, 273-298.
set.seed(314)
esp2=t(gtools::rdirichlet(n=6, c(1,1,5,1,1)))
Num2<-list(3,c(3,5),1,c(3,5,4))
Dem2<-list(5,4,2,c(1,2))
ObtainigValuePB(Num2,Dem2,esp2,6)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.