Hi, I am using a categorical variable that has two level for fixed-effect. I have two levels “High” and “Low” on ISlevel column. However, the value column in the result section only shows level “Low”.
This is the code I have used to run maaslin.
maaslin_result <-Maaslin2(
input_data = Features,
input_metadata = Metadata,
output = “maaslin_output”,
fixed_effects = c(“ISlevel”),
min_prevalence = 0,
min_abundance = 0,
normalization = “TSS”,
transform = “LOG”,
analysis_method = “LM”,
max_significance = ,
correction = “BH”,
standardize = TRUE
)
Attached is the screenshot of my metadata and result. all_results.tsv (46.6 KB)
When using linear models with categorical values one category has to be chosen as a reference that the other categories are then compared against (i.e. the reference is treated as a 0 in the model formula and the non-reference is treated as a 1). Therefore the coefficients and p-values shown in the results table are for models comparing high vs. low.
Hi Jacob,
Thanks for your response. So from what I understood, model took “high” category as a reference and compared against the “low” category. The results show features associated with only “low” category. Is there a way to find out features associated with “high” category?
The way to determine if it’s associated with the high category is to look at the coef column. A negative value in that column would indicate that the feature is higher in the reference category (i.e. high category in this case).