javascript - Changing unit on y-axis from million (M) to show multimillion (MM) in HighCharts - Stack Overflow

I am binding data to a column chart via Javascript. the Y-axis shows the data unit in millions hence it

I am binding data to a column chart via Javascript. the Y-axis shows the data unit in millions hence it shows the character 'M' next to the plot point values. I checked the documentation but that didnt help. Is there a way i can format the unit to show as MM for multimillion?

Here's the 'M' on Y-axis that i want to be changed to 'MM' /

I am binding data to a column chart via Javascript. the Y-axis shows the data unit in millions hence it shows the character 'M' next to the plot point values. I checked the documentation but that didnt help. Is there a way i can format the unit to show as MM for multimillion?

Here's the 'M' on Y-axis that i want to be changed to 'MM' http://jsfiddle/r6V8Z/

Share asked Jul 30, 2012 at 10:24 Adnan HusseinAdnan Hussein 2611 gold badge4 silver badges14 bronze badges 1
  • Here it is resolved, jsfiddle/r6V8Z/1 – Adnan Hussein Commented Jul 30, 2012 at 11:03
Add a ment  | 

1 Answer 1

Reset to default 5

Update the Y-axis formatter to this:

yAxis: {
    labels: {
        formatter: function () {
            return this.value / 1000000 + 'MM';
        }
    },
    min: 0,
    title: {
        text: 'Rainfall (mm)'
    }
}

发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745044745a4608025.html

相关推荐

发表回复

评论列表(0条)

  • 暂无评论

联系我们

400-800-8888

在线咨询: QQ交谈

邮件:admin@example.com

工作时间:周一至周五,9:30-18:30,节假日休息

关注微信