Morris折线图中的Y值错误

时间:2019-06-05 21:29:51

标签: morris.js

我有一个Morris折线图,该折线图可以采集数据并显示出来。不幸的是,如我在下面的代码段中所示,Y轴值未正确绘制到正确的点。我该如何解决?

Morris.Area({
             element: 'area-example',
             data:[
                  {
                  "prosarmogi": "35",
                  "organa": "0",
                  "sximatismos": "0",
                  "nautilia": "0",
                  "minasEtos": "2019-03"
                },
                {
                  "prosarmogi": "93",
                  "organa": "6",
                  "sximatismos": "2",
                  "nautilia": "0",
                  "minasEtos": "2019-04"
                },
                {
                  "prosarmogi": "23",
                  "organa": "18",
                  "sximatismos": "106",
                  "nautilia": "4",
                  "minasEtos": "2019-05"
                }
              ] ,
             xkey: 'minasEtos',
             xLabels:'month',
             ykeys: ['prosarmogi','organa','sximatismos','nautilia'],
             pointSize: 2,
             hideHover: 'auto',
             smooth:false,
             fillOpacity:0.2,            
             lineColors: ['orange','red','aqua','black']
           });
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/raphael/2.1.0/raphael-min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/morris.js/0.5.1/morris.min.js"></script>
 <div id="area-example"></div>

0 个答案:

没有答案