Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Separate Clade and Constraint #289

Open
bredelings opened this issue Oct 14, 2022 · 0 comments
Open

Separate Clade and Constraint #289

bredelings opened this issue Oct 14, 2022 · 0 comments
Labels
enhancement New feature or request

Comments

@bredelings
Copy link
Contributor

bredelings commented Oct 14, 2022

Currently the Clade object does double-duty, serving as both a clade and a constraint. We should separate these two roles. Many of the problems that caused #286 come from treating all constraints as if they were a clade, when they actually are not.

Currently a Clade object can be a normal clade, or it can be a negative constraint (NOT X), or it can be an "optional" constraint (A OR B OR C). We should separate Clades from Constraints by making new classes for constraints:

  • CladeConstraint(Clade)
  • NegativeConstraint(Constraint)
  • OrConstraint(vector)

We should also separate Clades and Constraints at the Rev language level, instead of using just the function clade( ) to construct all of them.

A lot of things that make sense for clades don't make sense for Constraints. For example, the taxon set for a NegativeConstraint doesn't really make sense.

Also, clades are normally considered to be the rooted form of a bi-partition, separating the include group (the clade taxa) from the exclude group (the other taxa) and the root. A clade should perhaps specify both the include group and the exclude group.

See some of the problems mentioned in #215 as well.

@bjoelle bjoelle added the enhancement New feature or request label Apr 15, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants