This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Custom SVG attributes with ETE

Is there a way to add attributes to the SVG output of the ETE tree drawing toolkit?

I am drawing phylogenetic trees as svg and would like to add the NCBI taxonomy ID as ID attribute to the node in the SVG. This would let me select them easily with java script, when using the SVG in a html page.

svg etetoolkit phylogenetic-tree

1 answer

Unfortunately this is not possible. The closest you can get is to generate a png image and use the pixel map dictionary returned by the tree.render() function.

Log in to answer this question.