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

handling extra keyword arguments #206

Open
jeremymanning opened this issue May 3, 2018 · 0 comments
Open

handling extra keyword arguments #206

jeremymanning opened this issue May 3, 2018 · 0 comments

Comments

@jeremymanning
Copy link
Member

If the user passes in non-hypertools keyword arguments, we should pass them to our plotting backend. This is somewhat non-trivial in that we need to handle the case where the user wants different values for different elements of the to-be-plotted data list. I think what should happen is:

  • if data is not a list, just pass along additional keywords without modifying them
  • if data is a list:
    • make sure that every keyword argument's value is a list of the same length. (if not, truncate or copy values to make the lengths match; if the user passes in a too-short list, throw an error)
    • for each to-be-plotted thing, pass (to matplotlib or other backend plotting machinery) a dictionary of keyword arguments that's constructed by taking the keys from the original keyword argument dictionary and setting the values of those keys to the corresponding elements of the keyword argument lists.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant