I’m running R 4.2.1 and Maaslin2 1.10.0.
taxonomy_4_dams.csv (198.5 KB)
metadata_4_dam.csv (3.0 KB)
I’ve attached my data, and below is the full code.
fit_dam4_10 = Maaslin2(
input_data = taxonomy_4_dams,
input_metadata = metadata_mom_2,
min_prevalence = 0.1,
min_abundance = 0.0001,
max_significance = 0.05,
normalization = "TSS",
output = "v4dams_output_10",
fixed_effects = c("Txt_Dose"),
reference = c("Txt_Dose,VEH_10")
)
fit_dam4_12 = Maaslin2(
input_data = taxonomy_4_dams,
input_metadata = metadata_4_dam,
min_prevalence = 0.1,
min_abundance = 0.0001,
max_significance = 0.05,
normalization = "TSS",
output = "v4dams_output_12",
fixed_effects = c("Txt_Dose"),
reference = c("Txt_Dose,VEH_12")
)
fit_dam4_14 = Maaslin2(
input_data = taxonomy_4_dams,
input_metadata = metadata_4_dam,
min_prevalence = 0.1,
min_abundance = 0.0001,
max_significance = 0.05,
normalization = "TSS",
output = "v4dams_output_14",
fixed_effects = c("Txt_Dose"),
reference = c("Txt_Dose,VEH_14")
)
fit_dam4_16 = Maaslin2(
input_data = taxonomy_4_dams,
input_metadata = metadata_4_dam,
min_prevalence = 0.1,
min_abundance = 0.0001,
max_significance = 0.05,
normalization = "TSS",
output = "v4dams_output_16",
fixed_effects = c("Txt_Dose"),
reference = c("Txt_Dose,VEH_16")
)
dam4_10_results <- fit_dam4_10$results
dam4_12_results <- fit_dam4_12$results
dam4_14_results <- fit_dam4_14$results
dam4_16_results <- fit_dam4_16$results
dam4_10_results$ref <- c(rep("VEH_10", times = 2051))
dam4_12_results$ref <- c(rep("VEH_12", times = 2051))
dam4_14_results$ref <- c(rep("VEH_14", times = 2051))
dam4_16_results$ref <- c(rep("VEH_16", times = 2051))
dam4_results_combined <- rbind(dam4_10_results, dam4_12_results, dam4_14_results, dam4_16_results)
dam4_results_combined <- dam4_results_combined %>%
dplyr::select(feature, ref, value, coef, stderr, pval)
dam4_results_combined$qval <- p.adjust(dam4_results_combined$pval, method = "BH")
write.table(dam4_results_combined, file = "C:\\Users\\hharder1\\Documents\\dam4_results_combined.csv", sep=",", row.names = FALSE)
Here is a screenshot of the problem:
The value column should list the levels of Txt_Dose from the metadata file, but instead just returns 2-7. If I was 100% which level was represented by each value, that would work, but I’m not sure.