Adjusting charts: Line chart
Summary: Information about adjusting the Line chart interactively. They can be useful if you're doing a presentation and need to illustrate changes.
Note
If you don't like the line being drawn outside of the chart area
(ie in the
margins where the title or the labels are) you can use the
outofboundsClip
option.
The Line chart can be adjusted by dragging the line(s) up and down. When you click on a line to adjust it (and hold the mouse button down) you can then retrieve the relevant details of that point from the registry:
RGraph.Registry.get('adjusting.shape');
<script> line = new RGraph.Line({ id: 'cvs', data: [ [45,74,84,85,45,35,65,68,87,97,45,34,12], [15,14,12,16,18,19,14,12,74,84,95,65,35] ], options: { xaxisLabels: ['Kev','Matt','Rich','Dave','Iggy','Polly','Fiona','Fred','Pete','Lou','Fred','Bob'], linewidth: 2, marginInner: 10, shadow: false, adjustable: true, title: 'An adjustable line chart', outofbounds: true, spline: true, tickmarksStyle: 'circle', tickmarksSize: 5 } }).draw(); </script>