[Scilab-users] grayplot

Samuel Gougeon sgougeon at free.fr
Fri Oct 28 15:41:16 CEST 2016


Le 28/10/2016 14:12, Rafael Guerra a écrit :
> Hi Samuel,
>
> Fyi, on my Scilab 5.5.2 (64-bit) Win 7 configuration, the code here below still fails for one xfarcs() call.
> Uncommenting the second xfarcs() call does fix the plot (attached).
> It looks like a bug. Or could it be only an issue with my configuration?
no, it's a bug in this code:
>
> /////// START OF CODE
> clf();
> x=[8030 8040 7998 8008 8037 7956 7937 7963 7919 7920];
> y=[9478 9533 9578 9590 9597 9626 9627 9723 9766 9768];
> z=[-2.39965177 1.81709373 -1.14068067 -2.95249772 -3.25881290 1.36802530 -1.46287727 ...
> -6.40911865 1.03929353 1.49115121];
>
> xm = min(x); xM = min(x); dx = strange(x);
xM = max(x);
> ym = min(y); yM = min(y); dy = strange(y);
yM = max(y)

Then it works.
You may note as well that
> colorbar(zm,zM);
should rather be replaced with
colorbar(zm, zM, [1 nc])

because the grey added in nc+1 position must not belong to the color scale.

Samuel




More information about the users mailing list