NVD3 time formatting , line with focus chart
问题 I'm using a fairly simple example of nvd3 line with focus chart. myData returns a JSON object from my php file of which the x-cordinates are numbers from 0-23. I would like to know how to format the x-axis in hours format. d3.json('get_data.php', function (error, myData) { // Renders a line chart (function () { nv.addGraph(function () { var chart = nv.models.lineWithFocusChart(); chart.xAxis .tickFormat(d3.format('')); chart.yAxis .tickFormat(d3.format('')); chart.y2Axis .tickFormat(d3.format