plotly / plotly/plotly_matlab

swarmchart not working correctly (doesn't present any jittering)

Open
#184 0 comments 0 reactions 1 assignee View on GitHub

@gilbertogalvis is already working on this.

Since Sep 8, 2021.

documentation
Dominant language
MATLAB
Stars
413
Forks
166
PR merge metrics
No merged PRs in 30d

Description

When using swarmchart() data is supposed to be offset (jittered) in the x-dimension for easier visualization. However, this isn't happening and data is just being plotted and stacked on its original value:

For example:

rng(1)

x = [ones(1,500) 2*ones(1,500) 3*ones(1,500)];
y1 = 2 * randn(1,500);
y2 = 3 * randn(1,500) + 5;
y3 = 5 * randn(1,500) + 5;
y = [y1 y2 y3];
swarmchart(x,y)

fig2plotly();

Expected and generated (https://chart-studio.plotly.com/~xarico10/337/#/) plots:
Captura de Pantalla 2021-07-26 a la(s) 12 08 34 a  m
Captura de Pantalla 2021-07-26 a la(s) 12 08 47 a  m

Examples on using swarmchart() can be found on:
https://www.mathworks.com/help/matlab/ref/swarmchart.html#responsive_offcanvas

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.