Google Charts Visualization Column Chart axis formatting and column colors

前端 未结 8 942
不知归路
不知归路 2020-12-25 15:17

\"chart\"

I have this Column Chart using Google\'s Visualization Chart API tools. How would I make it so the y-

相关标签:
8条回答
  • 2020-12-25 15:36
    var max=Math.max(1,10,15,20);(u have to pass the values what the values u have)
    var maxvalue= max / 4;
    var res=Math.floor(maxvalue);
    res=res+1;
    var remin= max % 4;
    if(res != 0) {
        maxvalue=(res * 4);
    }
    else
        maxvalue= 4;
    

    use the above code its working fine for me.

    0 讨论(0)
  • 2020-12-25 15:38

    Simply use hAxis.format

    example :

    hAxis: {minValue:0,format:'0'},
    

    format 0 = Digit

    0 讨论(0)
提交回复
热议问题