x 축에 0에서 2049 사이의 값이 있다고 가정합니다. 값은 시리즈입니다. 0500100015002000, 즉 500 개의 눈금마다 표시하기 위해해야 할 일은 아직 예제를 찾지 못했습니다. 나는 max-labels를 시도했지만, 나의 값이 2000 이상이기 때문에 나는 500의 배수를 얻지 못한다. 이것을 달성 할 방법이 있는가?ZingChart는 x 축에 값의 배수를 표시합니다.
2
A
답변
4
scale-x
이 있으십니까? scale-y
을 의미합니까?
scale-y
에 대해 이야기하는 경우 minValue
, maxValue
및 step
을 저울 사이에 설정할 수 있습니다. 모두 개별적으로 설정하거나 values: 'minValue:maxValue:step'
과 같이 설정할 수 있습니다. itemsOverlap
은 높이 또는 너비가 위 또는 아래 항목과 겹치더라도 모든 항목을 렌더링하도록합니다.
이 대답 경우
var myConfig = {
\t type: 'bar',
\t scaleY: {
\t values: '0:2000:500',
\t maxItems: 5,
\t itemsOverlap: true,
\t },
\t series: [
\t \t {
\t \t \t values: [2235,4442,3367,1389,2325,3334,4567,2385]
\t \t }
\t ]
};
zingchart.render({
\t id: 'myChart',
\t data: myConfig,
\t height: '100%',
\t width: '100%'
});
html, body {
\t height:100%;
\t width:100%;
\t margin:0;
\t padding:0;
}
#myChart {
\t height:100%;
\t width:100%;
\t min-height:150px;
}
.zc-ref {
\t display:none;
}
<!DOCTYPE html>
<html>
\t <head>
\t \t <script src= "https://cdn.zingchart.com/zingchart.min.js"></script>
\t </head>
\t <body>
\t \t <div id="myChart"><a class="zc-ref" href="https://www.zingchart.com">Powered by ZingChart</a></div>
\t </body>
</html>
저울 문서 :
https://www.zingchart.com/docs/tutorials/chart-elements/configure-chart-scales/
https://www.zingchart.com/docs/api/json-configuration/graphset/scale-x/
실제로 (500) 내 값 시리즈의 multples해야 x 축, 그리고 그들이 2000 더있어, – Spiff