lmaurits / BEASTling

A linguistics-focussed command line tool for generating BEAST XML files.
BSD 2-Clause "Simplified" License
20 stars 6 forks source link

Make TreePrior.add_state_nodes use state instead of beastxml #251

Open Anaphory opened 4 years ago

Anaphory commented 4 years ago

This line https://github.com/lmaurits/BEASTling/blob/ba264911ff591dbd3487a519c5faa24ec623fa3d/beastling/treepriors/base.py#L42 is the only one in TreePrior.add_state_nodes that makes use of the argument beastxml, instead of its beastxml.state attribute, and for a frivolous purpose. We should make the tree prior generally aware of tip calibrations (so eg. the Yule Prior can insist that there be none), and then make add_state_nodes only aware of the state to put its own state nodes into.