alifestd_mark_clade_faithpd_asexual

alifestd_mark_clade_faithpd_asexual(phylogeny_df: DataFrame, mutate: bool = False, *, mark_as: str = 'clade_faithpd') DataFrame

Add column clade_faithpd, containing sum branch length among descendant noes.

The output column name can be changed via the mark_as parameter.

Branch length is defined as the difference between the origin time of the node and the origin time of its ancestor.

A topological sort will be applied if phylogeny_df is not topologically sorted. Dataframe reindexing (e.g., df.index) may be applied.

Input dataframe is not mutated by this operation unless mutate set True. If mutate set True, operation does not occur in place; still use return value to get transformed phylogeny dataframe.