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

Improve checkpoint for divergence colors provided in configuration file #36

Merged
merged 3 commits into from
Mar 23, 2022

Conversation

Cecilia-Sensalari
Copy link
Collaborator

@Cecilia-Sensalari Cecilia-Sensalari commented Mar 23, 2022

  • Module fc_configfile.py now warns and exits if divergence_colors configuration file field was left empty or if the color names are not recognized by matplotlib (e.g. misspelled names)
  • Module setup_correction.py now checks whether the amount of colors provided in the configuration file field divergence_colors is enough: it must be at least equal to the number of divergence nodes in the lineage that goes from the focal species back to to the second-to-last divergence node before the root (the root node is ignored because the divergence(s) at this node will not be rate-adjusted). This way there are enough colors to depict all of the divergence lines in the mixed Ks plot.
  • Few other edits made to match the general style of logging messages

- Check if divergence color list in the
  configuration file is empty and+
  check if it contains at least as many colors
  as the number of internal nodes in the lineage
  that leads to the focal species (backbone of
  the tree plotted in the PDF or as ASCII).
- Warns and exit if colors in configuration
  file field "divergence_colors" are found
  to be not compatible with matplotlib, the
  package that is going to use them later
  on to generate the Ks plot.
  E.g. misspelled colors
@Cecilia-Sensalari Cecilia-Sensalari merged commit 621191f into master Mar 23, 2022
@Cecilia-Sensalari Cecilia-Sensalari deleted the fix_colors branch March 23, 2022 12:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant