Replies: 1 comment 1 reply
-
very comprehensive outlook, thank you! let's say we have something like:
and we want to introduce kwargs as plotting options. Is there any recommended, best-practice way to introduce them? Like, would you suggest passing them to the class itself and then have the functions "look" at them to decide how to behave, or just pass specific kwargs to each function? The first method seems more tidy, but the second a little more logical, as the user can think of the plotting "options" after calling the plotting function. I would result in many more lines of code though, so more room for errors. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
by @ancarnevali
There are a few ways I might tackle the problem of interactive plots with user-defined filtering criteria, based on what I understood from the question.
Plotly and Notebooks
3-4
assuming3-4
is one of the axes)kwargs and functions
Classes
Since you mentioned classes (and maybe you've seen this already or already know the content) figured it was worth mentioning Taylor's lecture on Python classes. Btw, not suggesting all of the above necessarily, just a bunch of ideas that come to mind.
GUIs
A lot of the above comments can mimic the functionality of GUIs/standalone applications without the steeper learning curve, but since you mentioned GUIs, just as a future reference thing, thought it might be worth mentioning flask. Also, nanoHUB's support of Rappture. Here's an example of what I believe is a Rappture tool. I've gotten pretty partial to the idea of using Colab Notebooks for lots of GUI and non-GUI like public-facing "try me" style implementations.
Hope this helps! Let me know if I missed something or if you have follow-up questions. Obviously, this is a lot, so don't feel like you have to look into every single thing I mentioned.
Beta Was this translation helpful? Give feedback.
All reactions