This is an archived static version of the original phylobabble.org discussion site.

Conversion of BEAST XML alignments to PHYLIP format

db60

Does anyone know a good way to convert the alignment within a BEAST XML file to PHYLIP (or Nexus, Fasta, etc)?

I could script it myself, but I assume the problem has already been addressed by others.

I realise the non-sequence data within the BEAST XML file will be lost, but for my purposes that’s OK.

Thank you very much, in advance.

Daniel Barker

arambaut

I have a program (called BEASTGen) that can convert BEAST to Nexus or FASTA:

https://code.google.com/p/beast-mcmc/downloads/detail?name=BEASTGen_v1.0.tgz

It loads alignments from one file and uses a template to convert to another. There are templates to create Nexus or FASTA formats but it should be possible to create others. I am working on some documentation here: http://beast.bio.ed.ac.uk/beastgen

Andrew