Can the graph be created using jqplot as shown below? The closest graph type is stacked
, but there are issues with coloring and point labels.
This jsfiddle showcases my attempt to create a bar chart with its legend and point labels. Is it possible to achieve the same look as the image?
var barchart = $.jqplot('chart1', [s1, s2, s3], {
animate: true,
grid: {
background: 'white',
drawBorder:false,
shadow: false
},
seriesColors: ['#73C6E8', '#F28570', '#727272'],
seriesDefaults: {
renderer: $.jqplot.BarRenderer,
rendererOptions: {
barPadding: 20,
barWidth: 25,
barMargin:10,
fillToZero: true
},
pointLabels: { show: true }
},
series: [
{ label: 'USA' },
{ label: 'India' },
{ label: 'South Africa' }
],
legend: {
show: true,
placement: 'outsideGrid',
location:'se',
background:'white',
border: 'white',
fontFamily: 'Gotham Medium',
fontSize:'12px',
renderer: $.jqplot.EnhancedLegendRenderer
},
axes: {
xaxis: {
renderer: $.jqplot.CategoryAxisRenderer,
ticks:xticks,
showTicks:false
},
yaxis: {
pad: 1.05,
ticks: yticks,
showTicks:false,
rendererOptions: {drawBaseline: false}
}
}
});