Generating taxa-wise unifrac distance Matrix using phyloseq
0
0
Entering edit mode
22 months ago
mail2steff ▴ 60

Dear All, I have OTU table obtained from qiime2 analysis and imported into phyloseq. I would like to get the unifrac distance between pair-wise species (not between the samples). in the output, I need distance matrix between the OTUs

      OTU1  OTU2  OTU3  OTU4  OTU5
OTU1   1   0.023  0.045  0.12   0.034
OTU2   :    :       :      :      :
OTU3   :    :       :      :      :
OTU4   :    :       :      :      :
OTU5   :    :       :      :      :


So I tried as follows:

unifrac_distance<-distance(ps, method="unifrac", type = "taxa")


But still I am getting matrix between the samples. How do I achieve OTU-wise unifrac distance matrix?

phyloseq R metagenomics unifrac • 1.0k views
0
Entering edit mode

I searched found this: UniFrac distance and DPCoA cannot be calculated for taxa-wise distances, because they use a taxa-wise tree as part of their calculation between samples, and there is no transpose-equivalent for this tree.