Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Hi @dstansby ,
As discussed in a previous #63 , I have updated and re-factored the previous code to add a line widget! 📈 🚀
LineBaseWidget
just uses plot, similar to theSliceWidget
, but without spinboxes. It is used as base by the following classes.LineWidget
uses the Shapes layer to plot intensities from a selected Image layer. So far, it only works with the shapeline
. I had to make a small change inbase
because of this line. I am using thebezier_curve
from scikit-image to get pixel coordinates. There is no interpolation in this current implementation.FeaturesLineWidget
is similar to theFeaturesScatterWidget
, but it has a third dropdown to group plots by a 'label' column.I provided 3 minimal examples and gifs to show how it looks like. I believe the
FeaturesLineWidget
gets interesting, for example, when one has features over time. It also works for single time points, although I think a scatter plot would make more sense then.I am particularly interested in using the LineWidget and the FeaturesLineWidget in other plugins I am working on.
Lastly, I tried to make them minimal and generalizable, but I have some difficulties setting what is minimal 😅 . I think I can count on your experience to help me there.
Best,
Marcelo