Morris.JS X-Axis Label Height
Posted
by
Aaron
on Stack Overflow
See other posts from Stack Overflow
or by Aaron
Published on 2013-10-31T19:45:01Z
Indexed on
2013/11/09
9:54 UTC
Read the original article
Hit count: 2183
I have a chart generated with Morris.JS but the labels on the x-axis are to long and being cut off due to the limited height of the area showing the labels.
The code below would render a graph that only shows the partial label for "COUNTY PARK ROAD ELEM.". How can I adjust the height of the label area to show the entire text?
The code is as follow
if ($('#IP1').length){
Morris.Bar({
element: 'IP1',
data: [
{x: 'COUNTY PARK ROAD ELEM.', yIndex: 376.92}
],
xkey: 'x',
ykeys: ['yIndex'],
labels: ['Index Points'],
ymax: 500,
barRatio: 0.2,
xLabelAngle: 45,
hideHover: 'auto'
});
}
© Stack Overflow or respective owner