ZingChart X axis negative display

I am trying to display a graph with negative values. The x axis should be in the central negative values ​​on the left and positive values ​​on the right. The graph will be displayed with values ​​from negative to positive. The following snapshot is attached to the one I am trying to achieve with zingchart.

Please help me with an example that will help me achieve the right schedule.

enter image description here

+4
source share
1 answer

values. values "values":"-10:10:2", -10 - , 10 - , 2 - . markers x = 0. . scale-y line-width 0, , , placement, .

"scale-x":{
  "values":"-10:10:2",
  "markers":[
    {
      "type":"line",
      "value-range":true,
      "line-width":2,
      "range":[0],
      "line-color":"#5B828E"
    }  
  ]
},
"scale-y":{
  "line-width":0,
  "tick" : {
    "placement":"ref-auto"
  },
  "item":{
    "placement":"ref-left"
  }
},

, . ZingChart, .

+5

Source: https://habr.com/ru/post/1598858/


All Articles