Skip to content

docs - color issues #437

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

Closed
danton267 opened this issue Oct 22, 2021 · 1 comment
Closed

docs - color issues #437

danton267 opened this issue Oct 22, 2021 · 1 comment

Comments

@danton267
Copy link
Member

danton267 commented Oct 22, 2021

x = linspace(0,3*pi,200);
y = cos(x) + rand(1,200);
c = linspace(1,10,length(x));
scatter(x,y,[],c)

fig2plotly(gcf);

prints this error, and the resulting plot is not colored

Unrecognized function or variable 'numColor'.
We had trouble parsing the scatter object.
This trace might not render properly.

same with this:

x = linspace(0,3*pi,200);
y = cos(x) + rand(1,200);
sz = 25;
c = linspace(1,10,length(x));
scatter(x,y,sz,c,'filled')

fig2plotly(gcf);

for this one, the middle of the plot is supposed to be transparent, it is all one color

x = randn(1000,1);
y = randn(1000,1);
s = scatter(x,y,'filled');

distfromzero = sqrt(x.^2 + y.^2);
s.AlphaData = distfromzero;
s.MarkerFaceAlpha = 'flat';

fig2plotly(gcf);

this plot when translated to plotly becomes unreadable:

load seamount x y z;

fig = figure;
scatter(x, y, 10, z);

title('Undersea Elevation');
xlabel('Longitude');
ylabel('Latitude');

fig2plotly(gcf);
@danton267 danton267 changed the title docs - missing color docs - color issues Oct 22, 2021
gilbertogalvis pushed a commit that referenced this issue Oct 26, 2021
gilbertogalvis added a commit that referenced this issue Oct 26, 2021
@gilbertogalvis
Copy link
Contributor

This issues was fixed by PR #461

Here the results

Test code 1

Screen Shot 2021-10-25 at 9 45 52 PM

Test code 2

Screen Shot 2021-10-25 at 9 46 17 PM

Test code 3

Screen Shot 2021-10-25 at 9 46 46 PM

Test code 4

Screen Shot 2021-10-25 at 9 47 18 PM

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

No branches or pull requests

2 participants