two of our students get Scilab freezes when they try to plot larger
vectors: for instance x,y are row vectors with 40000 elements.
When you try this :
plot([x2;x4])
Scilab seems freezing and then spits out some weird error like :
"error 999
glue: Handle 1 cannot be glued (invalid type)
at line 387 of function plot"
What does this mean ? Scilab 5.1.1 is installed on Winxp laptop.
Thanks in advance,
Bulek.
when plotting a matrix, the work is too huge.
it is quite different from plotting vectors.
you can see this by:
help plot;
"when y is a matrix, plot(y) plots each columns
of y versus vector 1:size(y,1)" so it is equal
to 40000 times of vector plots.
x2 and x4 are two different signals and we would like to plot them
both as y-values, but with different colors - I think that plot
([x2;x4]') is the right - but this doesn't help either. The problem is
that this works on other lab PCs (it takes some time, but it shows
graphs), but not on two certain laptops owned by students... I can't
find any reasonable explanation what is wrong (memory,something
else) ? I still think that Scilab should respond with more informative
warning...
Thanks in advance,
regards,
Bulek.
Hi,
I just got another weird Scilab response :
!--error 999
set: The handle is not or no more valid.
at line 4 of function generic_i_h called by :
line 2 of function %c_i_h called by :
line 358 of function plot called by :
plot([x2;x4]);
Regards,
Bulek.
It isn't: ([x2 x4]) will work, provided that x2 and x4 are column
vectors.
If you type size(x2), you should get [ 40000 1 ], not [1 40000].
Same thing for x4. Whether you get [ 1 40000] for both, you will have
to
transpose vectors before concatenating them: x2.'
Please compare size(x2.') with size(x2).
All this stuff is well explain in help plot:
---
If y is a matrix, plot(y) plots each columns of y versus vector 1:size
(y,1).
---
>- but this doesn't help either. The problem is
> that this works on other lab PCs (it takes some time, but it shows
> graphs), but not on two certain laptops owned by students... I can't
> find any reasonable explanation what is wrong (memory,something
> else) ?
a "," or " " and a ";" do not have the same effect in concatenation.
:-)
HTH
Regards
Samuel
An option might be to supplement your plotting needs with GnuPlot. If
the input vectors are in files (or can be written there) without too
much pain then it might be worth a spin. http://www.gnuplot.info/
--
Rich Webb Norfolk, VA