I have three covariates but I want the summary plot to only contain two of the covariates and they should be represented by a heatmap. When I run the code below no summary plot is generated.
fit_out ← maaslin3(input_data = abundance_data_df,
input_metadata = metadata_maaslin_Season_age,
output = ‘MAASLIN_SEASON_AGE_5’,
formula = ‘~ Age + Season + read_depth + (1|q3_record_id)’,
normalization = ‘CLR’,
transform = ‘NONE’,
warn_prevalence = FALSE,
augment = TRUE,
standardize = TRUE,
plot_summary_plot = TRUE,
plot_associations = TRUE,
max_pngs = 100,
summary_plot_first = 50,
heatmap_vars = c(“Age”, “[Season] [Dry season]”)
)
Hi, I’m pretty sure something is different between the heatmap variables you’re specifying and what’s actually available in your output table. Can you post the full MaAsLin 3 log or list what the unique names are in the name column of your output table? The full log will tell you why the summary plot couldn’t be produced and what the valid options are, and the name column of your output table will contain the valid options to include in the heatmap.
Will
This is the information from the log: INFO::The following specified variables were not
found in the associations: [Season][Dry season]
and the unique names in the name column of the output are : read_depth, Age, and SeasonWet season. I ran heatmap_vars = c(“Age”, “[Season][Wet season]”) but I till did not get the summary plot.
Based on that output, the heatmap vars should be "Age", "SeasonWet season" right?
Yes that should be it. i’m not sure i’m writing it properly in the code as this: " heatmap_vars = c(“Age”, “[Season][Wet season]”) “ doesnt still print the summary plot
Sorry, I mean it should literally be: heatmap_vars = c("Age", "SeasonWet season")
Thanks. It’s working now. I had to change all my entries of ‘Wet season’ to just ‘Wet’ under the Season column of my input metadata file and then use heatmap_vars = c(“Age”, “Season Wet”). seems like the code does not allow levels with whitespace
Hmm, whitespace should work, but glad you got it working!
1 Like