alifestd_add_inner_knuckles_polars

alifestd_add_inner_knuckles_polars(phylogeny_df: DataFrame) DataFrame

For all inner nodes, add a subtending unifurcation (“knuckle”).

Parameters

phylogeny_dfpolars.DataFrame

The phylogeny as a dataframe in alife standard format.

Must represent an asexual phylogeny with contiguous ids and topological sort order.

Returns

polars.DataFrame

The phylogeny with knuckle nodes added for each inner node.

See Also

alifestd_add_inner_knuckles_asexual :

Pandas-based implementation.