Skip to content

Polytomy collapsing #3011

@hyanwong

Description

@hyanwong

Here's a quick demo of the visual scheme I have come up with for condensing trees with polytomies, so we show only the lineages relating to a set of tracked samples (tips in cyan). Such samples might represent (say) a geographical region, or a covid Pango lineage. Here's an example, followed by the suggested scheme:

Screenshot 2024-10-07 at 19 07 59

Condensed:

Screenshot 2024-10-07 at 23 29 23

Two things are going on here:

  1. nodes at the top of a clade of entirely untracked samples (here node 36) are collapsed with a. triangle showing the number of samples underneath as "+n" (as in Allow multi-sample tips for Tree.draw_svg() #3010).
  2. where there are 2 or more lineages containing entirely untracked nodes that are part of a polytomy, that polytomy is collapsed into a dotted line (followed by "+n/m" where n is the number of samples and m is the number of additional branches in the polytomy)

Optionally (3rd plot), we can also collapse nodes that consist of entirely tracked samples (here node 39) into a triangle/trapezium:

Screenshot 2024-10-07 at 23 31 24

Does this look like a reasonable approach? I'm not sold on the "+n/m" notation but it was the most succinct/consistent that I could come up with.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions