A very simple question, but I could not figure it out ... I tried using jqplot to create a line graph with a vertical y-axis label. Based on the jqplot website example , all I need is to use this plugin jqplot.canvasAxisLabelRenderer.min.js. I tried it on the spot, but it didn't work. Can someone give me a hint of this? Below is a demonstration of my problem.
Below is my code:
$(document).ready(function(){
$.jqplot.config.enablePlugins = true;
var s1 = $.parseJSON($('#x_indi_val').text());
$.jqplot('chart1', [s1], {
seriesDefaults: {
showMarker:false,
pointLabels: { show:false } ,
},
series:[
{label:'Individuals'}
],
axes: {
xaxis: {
label :'Time units',
pad: 0,
},
yaxis: {
label: 'Number of individuals',
}
},
legend: {
show: true,
location: 'ne',
placement: 'inside',
fontSize: '11px'
}
});
});
source
share