> I have 4 different series, I have been able to graph the four series in
> the same display with different colors. But I would like to add a simple
> box with a legend indicating each color meaning. I don't know how to do
One way to make the box is as a RealTuple with MathType
(x, y, s) and ScalarMaps x -> XAxis, y -> YAxis and
s -> Shape. Create the box as a VisADLineArray that
you pass to the setShapes() method of the ShapeControl
you get from the getControl() method of your ScalarMap
to Shape. See visad/examples/Test47.java for an example.
For the text label, make a RealTuple with MathType
(x, y, t) where t is a TextType, and a ScalarMap
of its t to Text. See visad/examples/Test45.java for
> My Yaxis values range from -40 to 10, I would like to have the X axis at
> 0 instead of -40.
For this, you may need to turn the box off (call the
setBoxOn(false) method of your DisplayRenderer), and draw
an X axis as a Shape or as a Gridded2DSet with manifold
dimension = 1 (i.e., a line).
> Another question is what I should do to have values each 3 or 4 ticks, I
> have tried with this:
> Ando did not work.
Perhaps Don nows the answer to this.