Next: Graphing words in defuns, Previous: The final version, Up: Print Whole Graph [Contents][Index]
print-graphWe can test the print-graph function with a short list of numbers:
Y-axis-column,
graph-body-print, and print-graph (in addition to the
rest of the code.)
(print-graph '(3 2 5 6 7 5 3 4 6 4 3 2 1))
eval-expression).
yank).
Emacs will print a graph that looks like this:
10 -
*
** *
5 - **** *
**** ***
* *********
************
1 - *************
| | | |
1 5 10 15
On the other hand, if you pass print-graph a
vertical-step value of 2, by evaluating this expression:
(print-graph '(3 2 5 6 7 5 3 4 6 4 3 2 1) 2)
The graph looks like this:
20 -
*
** *
10 - **** *
**** ***
* *********
************
2 - *************
| | | |
1 5 10 15
(A question: is the ‘2’ on the bottom of the vertical axis a bug or a feature? If you think it is a bug, and should be a ‘1’ instead, (or even a ‘0’), you can modify the sources.)