I was using a bar chart but what wanted to use an area chart instead. One of our custom label functions overrides the printing of every label with only the highest point. This works in Line and Bar Charts but does not print anything in Area charts.
barChart = new dhtmlXChart({
view: "bar",
container: histogram_id,
value: "#routes#",
color: "#dddddd",
width: 10,
xAxis: {
title: "Hour",
lines: false,
template: function (obj) {
// The following hack displays only each hour interval along the xAxis, excluding 00:00
if (obj.interval.substring(3, 5) == '00' && obj.interval.substring(0, 2) != '00')
return obj.interval.substring(0, 2);
else
return "";
}
},
yAxis: {
title: "Routes",
template: "{obj}",
lines: false
},
label: function (obj) {
if (obj.isMax == true)
return obj.interval + " (" + obj.routes + ")";
else
return "";
}
});
barChart.parse(<mydata>, "json");