Skip to content

Deprecate Tree.newick and replace with Tree.as_newick (or similar) #1671

@jeromekelleher

Description

@jeromekelleher

The default behaviour of Tree.newick of making node labels the sample ID + 1 is horrible, and makes it very hard to integrate well with other libraries. This was done originally for compatibility with ms, but that's not a good reason to keep it.

We should make a new function which does the right thing. It cant use the same infrastructure (we don't need to fiddle with the C code, for now). We can keep Tree.newick indefinitely, but it should be marked as deprecated.

@hyanwong - are there other phylo-type functions we need to consider deprecating which inherited this behaviour?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Python APIIssue is about the Python API

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions