Hi everyone,
I have some questions about “pcoa” command.
The output ofthis command are two files ending in *pcoa, and *pcoa.loadings,but I can’t find the file ending in *pcoa. However, there is a file ending in *axes.
Most PCoA are based on unweighted unifrac or weighted unifrac. Is this command also based on unifrac? If not, how can I do PCoA based on unifrac?
Who can give me a R script to plot PCoA results
Thanks for your help!
The axes file contains the plotting coordinates for graphing the results so this is what you need. Maybe the *.pcoa is a typo in the logfile or something.
PCoA is just run on any distance matrix. It’s up to you what you want to run it on, you just need a phylip-formatted matrix to proceed. As you note, you can get these from the unifrac.unweighted/unifrac.weighted commands, but also from the dist.shared command (Bray-Curtis, Yue-Clayton theta, Jaccard etc).
If you want anything fancy you’ll need to have a play around a bit, but for a very basic plot:
You’ll just need to manually work out the X/Y values for placing your legend (hopefully there will be a bit of an empty spot on your graph where you can stick it).