score:-1
for this purpose, you can use chart.js i think, this may help
score:1
you can try fusioncharts instead to make your charting process delightful. it allows you to instantly create the chart without requiring extensive knowledge of the data structures. and did i mention that the charts look beautiful?
using fusioncharts stacked charts, i have created a sample for you in jsfiddle using your data.
fusioncharts.ready(function() {
var revenuechart = new fusioncharts({
type: 'stackedcolumn2d',
renderat: 'chart-container',
width: '550',
height: '450',
dataformat: 'json',
datasource: {
"chart": {
"caption": "alex-john-mark",
"subcaption": "",
"xaxisname": "month",
"yaxisname": "units",
"palettecolors": "#4a148c,#004d40, #ff6f00",
"bgcolor": "#ffffff",
"borderalpha": "20",
"showcanvasborder": "0",
"useplotgradientcolor": "0",
"plotborderalpha": "10",
"legendborderalpha": "0",
"legendshadow": "0",
"valuefontcolor": "#ffffff",
"showxaxisline": "1",
"xaxislinecolor": "#999999",
"divlinecolor": "#999999",
"divlineisdashed": "1",
"showalternatehgridcolor": "0",
"subcaptionfontbold": "0",
"subcaptionfontsize": "14",
"showhovereffect": "1"
},
"categories": [{
"category": [{
"label": "january"
}, {
"label": "february"
}, {
"label": "march"
}
]
}],
"dataset": [{
"seriesname": "alex",
"data": [{
"value": "10"
}, {
"value": "20"
},
{
"value": "10"
}
]
}, {
"seriesname": "john",
"data": [{
"value": "0"
}, {
"value": "30"
},
{
"value": "20"
}
]
}, {
"seriesname": "mark",
"data": [{
"value": "0"
}, {
"value": "40"
},
{
"value": "0"
}
]
}]
}
}).render();
});
let me know if this solves your purpose.
Source: stackoverflow.com
Related Query
- How to create Stacked bar chart from JSON in chart.js
- How to create stacked bar chart using react-chartjs-2?
- How to create Bar chart that gets updated from new ajax requests with ChartJS?
- How do I create a stacked horizontal bar chart with Chart.js in React?
- How can I create a stacked bar chart with Charts.JS that displays relative rather than absolute values?
- ChartJs - stacked bar chart with groups - how to create second x-axis with stack id
- how to insert dynamic data from sql into chartjs stacked bar chart javascript
- How to create an animate-on-update Stacked Bar chart using Chart.js(or Chartist)?
- Chart.js Bar Chart - how to chart bars from 0
- How to display inline values in a stacked bar chart with Chart.js?
- Stacked bar chart starting from 0 - ChartJS React
- In Stacked horizontal bar chart how to remove the vertical line in Chart.js?
- How to remove border from stacked column chart in Chartkick - Chart.js
- How to create chartjs chart with data from database C#
- angular-chart.js : how to show numbers in each bar of stacked bar chart
- Chart.Js how to hide datapoints with "0" value in Stacked Bar Chart
- How do I create stacked chart with Chart.js version 2.0.0-beta
- How to plot chart from external JSON and format X-AXIS to show time using Chart.JS?
- Create stacked bar chart with a single dataset per stack
- How to create a chart with chartjs.org with data from an array?
- Unable to create Stacked Grouped Bar Chart with chart.js / react-chartjs-2 in React
- How to create a stacked donut chart in Angular 5
- How to prevent empty bars from taking up width in Chart.js bar chart
- How to remove the extra Y axis from a bar chart in chart.js
- Chart.js how to display multiple labels on multi bar stacked chart
- How to fetch data from Json file on charts(bar-chart/pie chart etc) in angular?
- ChartJS - would like to create a mixed chart with horizontal Bar and a dot to represent the answer from the current user
- How to fix a stacked logarithmic bar chart values to fit the grid
- how to highlight the bars in stacked bar chart of chart.js on clicking a legend
- How to create a chart.js scatter chart with data from two lists
More Query from same tag
- How to generate bubble chart (Chart.js) using data from database FILTERED by user in Django?
- Chart.js with React
- how change color of labels of legends of chart.js
- How do I customize y-axis labels and randomly pick the value from the data range for x-axis in Chart js
- Parse 2d int array to List of BubbleDataPoints
- How to change chartjs ticks orientation to 'slope right'?
- Chart.js — drawing an arbitrary vertical line
- Changing x axis labels in Chart.js line chart
- How to convert Data table to Json in Javascript
- Missing colors in my Chart.js, my data looks fine, but no color
- Drawing images on top of graph doesn't work with ChartJS
- Chartjs unselected lines on render
- Chartjs annotation plugin colored box colors get summed after switching back and forth
- Chart js footer
- Always show last tooltip on all datasets, leave the rest to display on hover? ChartJS
- how to make chartjs columns smaller in width for bar chart?
- Chart.js change vertical position of points
- Canvas is already in use. Chart with ID '0' must be destroyed before the canvas can be reused. chat.JS
- Add images inside bar chart in chart.js
- chartjs radar glowing edges effect
- Converting JSON data into Chart.js array from strings
- How to add tooltip for the inner doughnut
- Add padding between two y-axis scales using chart.js
- Chart JS grouped sub labels
- Chart.JS change Text Color
- Chart.js v2, remove padding/margin from radar chart
- How to change width of the chart using Chart.js
- chart is not getting updated from the values it received from Jquery
- who know how to put down the title of pie in ionic 2
- Create Chart using $getJSON and ChartJS