Axis 282 User Manual Page 28

  • Download
  • Add to my manuals
  • Print
  • Page
    / 80
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 27
Chapter II-12 — Graphs
II-260
Color as f(z) Example
If you have a graph that uses the color as f(z) mode, you may want to create a legend that identifies what
the colors correspond to. This section demonstrates using the features of the Legend operation for this pur-
pose.
Execute these commands, one-at-a-time:
// Make test data
Make /O testData = {1, 2, 3}
// Display in a graph in markers mode
Display testData
ModifyGraph mode=3,marker=8,msize=5
// Create a normal legend where the symbol comes from the trace
Legend/C/N=legend0/J/A=LT "\\s(testData) First\r\\s(testData)
Second\r\\s(testData) Third"
// Make a color index wave to control the marker color
Make /O testColorIndex = {0, 127, 225}
// Change the graph trace to use color as f(z) mode.
// Rainbow256 is the name of a built-in color table.
// The numbers 0 and 255 set the color index values that correspond to the
// first and last entries in the color table.
ModifyGraph zColor(testData)={testColorIndex,0,255,Rainbow256,0}
// Change the legend so that it shows the colors
Legend/C/N=legend0/J/A=LT "\\k(65535,0,0)\\W608 Red\r\\k(0,65535,0)\\W608
Green\r\\k(0,0,65535)\\W608 Blue"
The result is this graph:
-2
-1
0
1
-2 -1
0 1 2
3.0
2.5
2.0
1.5
1.0
2.01.51.00.50.0
Red
Green
Blue
Page view 27
1 2 ... 23 24 25 26 27 28 29 30 31 32 33 ... 79 80

Comments to this Manuals

No comments