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

Plot refactoring #207

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open

Plot refactoring #207

wants to merge 3 commits into from

Conversation

pabloitu
Copy link
Collaborator

@pabloitu pabloitu commented Nov 8, 2022

Draft PR

Started refactoring work on plotting functions. The idea, is that now plot wrapper functions can receive keywords, which will be then passed to matplotlib specific funcs. A class PlotArgs is created, contained the default options (categorized by usage), whose attributes would be updated on instantiation if a kw is passed.

If we do not want to break previous code, we could create a wrapper if the old plot_args is passed (now as optional), that returns a PlotArgs class.

PR Type

  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update (this pull request adds no new code)
  • This change requires a documentation update

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

feat: added option to plot test distribution's mean.
styl: homogenized plot_poisson_consistency_test and plot_consistency_test
…d can be instatiated using keywords. These kw can be passed from plotting functions, replacing the old plot_args dictionary. Example:

plot_spatial_dataset(data, figsize=(10,2), title='hola').

feat: Prepared plot_consistency_test as candidate to generalize plot_poisson_consistency_test. Should we leave poisson as a legacy function?
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