我需要将我的 OTU 表从我的 phyloseq 对象转换为数据框,以便我可以使用它来运行 PICRUSt2,但as.data.frame(physeq@otu_table)
不会使其成为数据框。我试过pie<-as.matrix(physeq@otu_table)
了,当我说它is.matrix(pie) #it says TRUE
时,但当我说它class(pie) #it says [1] "otu_table" attr(,"package") [1] "phyloseq"
甚至不会假装是一个数据框时:
pie<-as.data.frame(physeq@otu_table)
is.data.frame(pie)
#FALSE
我不能只使用我的 asv_mat 在我将它放入 phyloseq 对象之前,因为我必须从我的 phyloseq 对象中移除线粒体和叶绿体。这仍将在 asv_mat 中。
提前致谢