Skip to content

Add support for violin plot #936

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

Merged
merged 2 commits into from
May 31, 2021
Merged

Conversation

LUUUAN
Copy link
Contributor

@LUUUAN LUUUAN commented May 17, 2021

Thanks for contributing.

Description

This is the fix for issue #509

Two files are added: ViolinPlot.java and ViolinTrace.java. Also I modified the file trace_template.html so that violin plot can draw the inner box plot at the same time. Also, considering that the mean line of violin plot is also frequently used, it is also added into the trace_template.html but I comment the code (context.put("meanLine", "{visible: true}")) that draw the mean line in ViolinTrace.java because it doesn't perform well together with inner box plot. You can changed the code and style according to your preference.

Testing

Test is developed following the style of other plot tests.

@lwhite1
Copy link
Collaborator

lwhite1 commented May 22, 2021

the box and meanline options should be added to the builder rather than always including one and excluding the other

@LUUUAN
Copy link
Contributor Author

LUUUAN commented May 22, 2021

Ok

@LUUUAN
Copy link
Contributor Author

LUUUAN commented May 30, 2021

I have added two method to ViolinTrace.java to configure whether box plot and mean line will show up in the figure.

@lwhite1
Copy link
Collaborator

lwhite1 commented May 31, 2021

@LUUUAN This looks good. Thank you

@lwhite1 lwhite1 merged commit aa65d80 into jtablesaw:master May 31, 2021
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