jquery - HighStock x-axis displays numbers when category length is less than max value -
in highstock bar graph, x-axis displays numbers, if category length less max range. category values reading database. below code,
$(function () { chartoptions = new highcharts.chart({ chart: { renderto: 'container', type: 'column' }, title: { text: 'test', x: -20 }, xaxis: { categories: color, pointwidth: 28, ordinal: false, min: 0, max: 10, labels: { rotation: -60, align: 'right', usehtml: true, style: { fontsize: '10px', fontfamily: 'proxima-nova,helvetica,arial,sans-seri', whitespace: 'nowrap', paddingleft: '10px', paddingright: '10px', paddingtop: '10px', paddingbottom: '10px' } }, title: { text: 'test2' } }, yaxis: { allowdecimals: false, min: 0, max: 15, title: { text: 'test3' } }, tooltip: { headerformat: '<span style="font-size:10px">{point.key}</span><table>', pointformat: '<tr><td style="color:{series.color};padding:0">{series.name}: </td>' + '<td style="padding:0"><b>{point.y}</td></tr>', footerformat: '</table>', shared: true, usehtml: true }, plotoptions: { column: { pointpadding: 0.2, borderwidth: 0 }, }, scrollbar: { enabled: true }, series: [{ name: 'orderlist', data: orderlist }, { name: 'historical', data: history }] }); });
if max property not set, labels comes in double line. how remove number ticks x-axis.
in case when set max param 10, print 10 ticks, , if have less points, categoreis / ticks printed until max value achieved.
jquery asp.net highstock
No comments:
Post a Comment