In Series I have used
series: [
{
name: 'High usage',
data: highUsage,
color: '#009DDB'
},
{
name: 'Normal usage',
data: normalUsage,
color: '#83C580'
}
]
In tooltip
tooltip: {
crosshairs: [true, true],
formatter: function() {
}
}
My JSON format is
"data": {
"low_usage": [
{
"percentage": 77.9,
"machine": 3
},
{
"percentage": 22.8,
"machine": 1
}
],
here everything working fine, but I need to show the number of machines also in tooltip like Percentage: 100% (3 machines)
What I have to do in the formatter.
{
"data":{
"normal_usage":[
{
"machine":1,
"percentage":4.3
},
{
"machine":0,
"percentage":0
}
],
"high_usage":[
{
"machine":0,
"percentage":0
},
{
"machine":0,
"percentage":0
}
]
},
"error_path":"no error",
"success":true
}
This is my input format I send the data based on high usage and low usage