Skip to content

Color variation not working using swarmchart #181

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

Open
xarico10 opened this issue Jul 26, 2021 · 0 comments
Open

Color variation not working using swarmchart #181

xarico10 opened this issue Jul 26, 2021 · 0 comments
Labels
documentation documentation

Comments

@xarico10
Copy link
Contributor

xarico10 commented Jul 26, 2021

The input argument c isn't changing marker's color when using swarmchart().

rng(1)
x1 = ones(1,100);
x2 = 2 * ones(1,100);
x3 = 3 * ones(1,100);
y1 = 2 * randn(1,100);
y2 = [randn(1,50) randn(1,50) + 4];
y3 = 5 * randn(1,100) + 5;

swarmchart(x1,y1,'red')
hold on
swarmchart(x2,y2,'green')
swarmchart(x3,y3,'blue')
hold off

fig2plotly();

The previous code should plot 3 different series with 3 different marker's color (red, green and blue), however, they're all being plotted with the default plotly colors.

Expected and generated (https://chart-studio.plotly.com/~xarico10/329/#/) plot:
Captura de Pantalla 2021-07-25 a la(s) 11 51 34 p  m

Captura de Pantalla 2021-07-25 a la(s) 11 51 46 p  m

Examples on using the c input argument on swarmchart() can be found on:
https://www.mathworks.com/help/matlab/ref/swarmchart.html#mw_41bfbeb8-a8e2-4fd1-a6d8-c4b05cd5d8d8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation documentation
Projects
None yet
Development

No branches or pull requests

2 participants