Adding multiple rows to AmCharts database
I just started working with AmCharts Javascript Graphics Card Library. My requirement is to draw one chart with one value axis and one date axis. And I have datasets showing results for different team members.
Plus I have one array that stores the consolidated performance of team members, which basically shows the performance of companies.
I also tried to create separate charts using the new AmCharts.AmGraph () method, but amCharts asks for the data provider at the chart level. Not at the graph level.
Please, help
source to share
Just add a second graph to the "Graphs" section ...
{
"id": "g2",
"bullet": "round",
"bulletBorderAlpha": 1,
"bulletColor": "#00FF00",
"bulletSize": 5,
"hideBulletsCount": 50,
"lineThickness": 2,
"title": "green line",
"useLineColorForBulletBorder": true,
"valueField": "value2"
}
and also add a second stream to your data ...
{
"date": "2012-07-27",
"value": 13,
"value2": 10
}, {
"date": "2012-07-28",
"value": 11,
"value2": 12
}
As you can see, I've added "value2", which will be used as rough data for the second graph. Just make sure you reference this value in the graph section (as you will see in the "valueField" at the top of the code above.
You can see a working example at http://jsfiddle.net/srp8313j/ . I only added a few points for the second graph so you can know what to do.
source to share