B1MODImodel | R Documentation |
This function calculates the value of the FBM regression, defined by:
\mu_{it}=a_{i1}+a_{i2}\cdot\text{alr}(x_{i,(t-1)})+a_{i3}\cdot\text{Balance}(x_{i,(t-1)})\text{ for }i=1,\dots, D-1\text{ where } D \text{ is the number of bacteria}
B1MODImodel(A, especie, E, EspecieMaxima, Tt)
A |
Matrix of dimensions ( |
especie |
Matrix that contains at row i the bacterial taxa of bacteria i at all time points. |
E |
Number of bacteria available |
EspecieMaxima |
Row in which the bacteria chosen as reference is in |
Tt |
Number of time points available. |
Returns a matrix. The row i contains the regression values of the bacteria i at all time points.
Creus-MartÃ, I., Moya, A., Santonja, F. J. (2021). A Dirichlet autoregressive model for the analysis of microbiota time-series data. Complexity, 2021, 1-16.
df<-data.frame(cbind(c(0.1,0.1,0.8),c(0.2,0.1,0.7)))
E=3
EspecieMaxima=3
set.seed(724)
A=matrix(c(-2:3),2,3)
Tt=2
B1MODImodel(A,df, E, EspecieMaxima,Tt)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.