The chart is using dates as X values.
This goes in the documents header:<script src="RGraph.common.core.js"></script> <script src="RGraph.scatter.js"></script>Put this where you want the chart to show up:
<canvas id="cvs" width="600" height="400">
[No canvas support]
</canvas>
This is the code that generates the chart:
<script>
var data1 = [['2013-01-01',50,'green'],['2013-02-01',10,'green'],['2013-11-31',35,'green'],['2013-12-31',25,'green']],
data2 = [['2013-03-31',54,'red'],['2013-06-06',45,'red'],['2013-04-06',13,'red'],['2013-08-23',32,'red']];
var scatter = new RGraph.Scatter({
id: 'cvs',
data: [data1,data2],
options: {
line: true,
xmin: '1 January 2013',
xmax: '2013-12-31',
labels: ['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec'],
textAccessible: true
}
}).draw();
</script>