Parses the nested <haplogroup> XML that Haplogrep distributes (for
example phylotree-rcrs-17's tree.xml) into the same data frame shape as
phylotree17, so any Haplogrep tree can be loaded, not just the bundled
snapshot. Each haplogroup's <details><poly> entries become its mutations.
Arguments
- file
Path to the tree XML.
- key
If
TRUE, return a dimoose key built withkeyFromLeads()instead of the data frame.
Value
A data frame with haplogroup, parent, depth, n_subclades
and mutations, or a dimoose object if key = TRUE.