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

specify axes parent #24

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

calboi91
Copy link

Add option to specify axes parent
Add option to not output handles if not requested

Add option to specify axes parent
Add option to not output handles if not requested
@calboi91 calboi91 mentioned this pull request Feb 16, 2021
Copy link
Owner

@bastibe bastibe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your pull request! I like it!

However, there are a few questions I would like to be addressed before merging. Could you comment on them?

end

end

if nargout > 0
varargout{1} = violins;
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why the change to varargout?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sometimes I run the function from the command line, and I don't want any output. This gives it the flexibility for that option in addition to the default output.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That doesn't make sense to me. If you don't assign the return value, you don't receive it. Please revert this part of the change before merging.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That was the point of this change. When I am running the function from the command line, sometimes I do not want to receive the return value.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please revert this change. If you do not want to receive the return value, put a semicolon at the end of the line.

violinplot.m Show resolved Hide resolved
@@ -197,6 +197,7 @@
obj.ShowData = args.ShowData;
obj.ShowNotches = args.ShowNotches;
obj.ShowMean = args.ShowMean;
uistack(obj.ViolinPlot,'bottom');
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why is the violin plot stacked to the bottom? I think I would generally expect the last plot to end up on top.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's mainly to help with selecting the scatter points using the data cursor or the select tool in the figure panel. With the violin plot on top, I can only select the violin plot and it is rather annoying to select the underlying scatter points.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Then we should change the plot order and plot the scatter points last. But stacking the Violin to the bottom is counterintuitive and might break plots.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Plot order is more of a visual feature, unless I am mistaken and you use the plot order for another function? I do not think it is that counterintuitive to stack Violin to the bottom using uistack since that is the purpose of that function.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Imagine someone plotting first a few lines, then a Violin. The Violin should definitely be atop the lines. We can not mess with uistack.

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.

2 participants