core.tree.make_tree

core.tree.make_tree(
    treestring=None,
    tip_names=None,
    format_name=None,
    underscore_unmunge=False,
    source=None,
)

Initialises a tree.

Parameters

Name Type Description Default
treestring str | None a newick or xml formatted tree string None
tip_names Iterable[str] | None a list of tip names, returns a “star” topology tree None
format_name str | None indicates treestring is either newick or xml formatted, default is newick None
underscore_unmunge bool replace underscores with spaces in all names read, i.e. “sp_name” becomes “sp name” False
source str | pathlib.Path | None path to file tree came from, string value assigned to tree.source None

Notes

Underscore unmunging is turned off by default, although it is part of the Newick format.

Returns

Name Type Description
PhyloNode