The bioBakery help forum

Longitudinal study and correcting for cage effect


Firstly, thank you very much for the work on MaAsLin2. It is a really helpful set of tools and the publication is very impressive (also with regards to the number benchmarking analyses).

I need some guidance with the analysis using MaAsLin2:


I have a longitudinal data set on mice with 5 time points and three treatment groups (control food, wildtype plant food and mutant plant food). The subjects were divided into 5 cages.

Detection of differentially abundant taxa at different time points

I understood that MaAsLin2 is not suitable for detecting differentially abundant taxa at specific time intervals as it is possible in the metagenomSeq fitTimeSeries() function. Am I correct with this assumption?

Is it possible to meaningfully include in the model the treatment, the sampling time points, the subject ID (because I have several measurements per subject) and the cage (to correct for any cage effect)?

In blunt terms, I would like to infer something like “feature A is significantly differential abundant in WT compared to the control at time point X while having corrected for any cage effect”.

Does it make most sense to split the data into subsets per sampling day and then add the cage as random_effect? Or can this be done in one go?

Many thanks for any advice

Hi @makrez - while it’s not possible to detect differentially abundant features at specific time intervals using MaAsLin 2, you can certainly split the data at different time points and run multiple MaAsLin 2 analyses each time using cage as random effect, which seems to be the right approach given your experimental design.

Thank you very much for your answer. Much appreciated.