Compute microbiomes for all individuals of current generation gathering all relevant object already computed.
compute_current_microbiome.RdCompute microbiomes for all individuals of current generation gathering all relevant object already computed.
Usage
compute_current_microbiome(
beta,
current_genotypes,
mother_microbiomes,
mean_microbiome,
noise = 0.1,
taxa_scale,
lambda = 0.5,
dir = F,
thetaX
)Arguments
- beta
A
matrixof taxa (rows) by SNPs (columns) representing the multiplicative effect of SNPs on taxa abundances. Typically the output ofcompute_beta_matrix_cluster()- current_genotypes
A
matrixof genotypes for the individuals of the current generation.- mother_microbiomes
A
matrixcontaining the CLR-transformed abundances from the microbiome of the current mothers.- mean_microbiome
A
numericvector representing the average abundances of the microbiome within the population.- noise
A
numericscalar indicating the standard deviation of the Gaussian noise to add during beta g constructioncompute_beta_g()(multiplicative genetic effect on taxa abundances).- taxa_scale
A
numericscalar to scale the noise added to each OTUs abundance, seecompute_beta_g().- lambda
A
numericbetween 0 and 1 controlling the relative contribution of the mother microbiome compared to the average microbiome.- dir
A
logical;- thetaX
A
matrixrepresenting the environmental effect (optional).
Value
A matrix of CLR-transformed abundances of the microbiome for each individual of the current generation.