我正在处理细菌焦磷酸测序数据,并使用 R 进行统计分析。我有 21 个样本和 7 种不同的处理方法。我将数据加载到 R phyloseq 中,获得:
> psR
phyloseq-class experiment-level object
otu_table() OTU Table: [ 7498 taxa and 21 samples ]
sample_data() Sample Data: [ 21 samples by 8 sample variables ]
tax_table() Taxonomy Table: [ 7498 taxa by 6 taxonomic ranks ]
phy_tree() Phylogenetic Tree: [ 7498 tips and 7497 internal nodes ]
Run Code Online (Sandbox Code Playgroud)
由于我发现处理之间(使用 adonis 函数)存在统计显着差异,因此我想知道哪些 OTU 在不同处理中具有不同的丰度。为此,我使用了 dunn.test 函数(包含 Kruskal-Wallis 测试),首先交换 OTU 表中的行和列以应用测试:
swap_otu_table <- t(otu_table(psR))
treatment <- c('A', 'A', 'A', 'B', 'B', 'B', …Run Code Online (Sandbox Code Playgroud)