X轴的Google Live图形值按降序排列

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了X轴的Google Live图形值按降序排列相关的知识,希望对你有一定的参考价值。

我正在将webview的google chart / graph用于我的ios / Objective c代码。我在Y轴(vAxis)上显示值,在X轴(hAxis)上显示日期,日期以升序显示(最早的日期在前),但是我想以降序显示(最新的日期在前),但我无法照着做。我尝试过一些类似

的事情
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js" SortOrder="Descending"></script> 

data.sort(
                                        column: 1,
                                        desc: true
                                        );

   hAxis: 
                                          format: 'd-MMM',
                                          direction: -1
                                      ,

但是它们都不起作用。

下面是示例html

<!DOCTYPE html>
<html>
    <head>
        <script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
        <script type="text/javascript">

            google.charts.load('current', 'packages':['line']);
            google.charts.setOnLoadCallback(drawChart);
            function drawChart() 

                var data = new google.visualization.DataTable();
                data.addColumn('datetime', '');
                data.addColumn('number', 'Temperature');
                data.addRows([
                              [new Date(2019,11,17,23,00,22),78.332001],
                              [new Date(2019,11,17,22,00,15),78.332001],
                              [new Date(2019,11,17,21,02,29),78.458000],
                              [new Date(2019,11,17,20,04,18),77.594002],
                              [new Date(2019,11,17,19,01,14),76.765999],
                              [new Date(2019,11,17,18,02,20),76.622002],
                              [new Date(2019,11,17,17,02,14),76.477997],
                              [new Date(2019,11,17,16,02,12),76.514000],
                              [new Date(2019,11,17,15,02,17),76.334000],
                              [new Date(2019,11,17,14,02,15),76.136002],
                              [new Date(2019,11,17,13,02,15),76.028000],
                              [new Date(2019,11,17,12,02,13),75.578003],
                              [new Date(2019,11,17,11,02,14),75.685997],
                              [new Date(2019,11,17,10,02,14),75.722000],
                              [new Date(2019,11,17,09,02,16),75.811996],
                              [new Date(2019,11,17,08,01,14),76.117996],
                              [new Date(2019,11,17,07,01,16),76.550003],
                              [new Date(2019,11,17,06,02,13),77.108002],
                              [new Date(2019,11,17,05,02,12),77.846001],
                              [new Date(2019,11,17,04,00,16),77.900002],
                              [new Date(2019,11,17,03,00,16),78.134003],
                              [new Date(2019,11,17,02,00,15),77.431999],
                              [new Date(2019,11,17,01,00,13),78.061996],
                              [new Date(2019,11,17,00,00,11),77.683998],
                              [new Date(2019,11,16,23,00,13),77.954002],
                              [new Date(2019,11,16,22,00,12),78.098000],
                              [new Date(2019,11,16,21,00,14),77.612000],
                              [new Date(2019,11,16,20,02,15),77.594002],
                              [new Date(2019,11,16,19,02,31),76.783997],
                              [new Date(2019,11,16,18,02,42),76.783997],
                              [new Date(2019,11,16,17,02,33),76.837997],
                              [new Date(2019,11,16,16,08,40),76.783997],
                              [new Date(2019,11,16,15,02,22),76.820000],
                              [new Date(2019,11,16,14,02,32),76.874001],
                              [new Date(2019,11,16,13,02,34),77.288002],
                              [new Date(2019,11,16,12,02,37),77.360001],
                              [new Date(2019,11,16,11,02,40),78.206001],
                              [new Date(2019,11,16,10,02,46),77.648003],
                              [new Date(2019,11,16,09,02,33),78.295998],
                              [new Date(2019,11,16,08,02,42),78.026001],
                              [new Date(2019,11,16,07,02,25),77.648003],
                              [new Date(2019,11,16,06,05,30),78.043999],
                              [new Date(2019,11,16,05,02,35),77.468002],
                              [new Date(2019,11,16,04,00,44),77.720001],
                              [new Date(2019,11,16,03,00,28),76.514000],
                              [new Date(2019,11,16,02,00,31),76.982002],
                              [new Date(2019,11,16,01,00,35),78.043999],
                              [new Date(2019,11,16,00,01,27),77.989998],
                              [new Date(2019,11,15,23,01,30),78.889999],
                              [new Date(2019,11,15,22,01,22),78.800003],
                              [new Date(2019,11,15,21,01,47),78.835999],
                              [new Date(2019,11,15,20,01,33),78.800003],
                              [new Date(2019,11,15,19,01,26),78.620003],
                              [new Date(2019,11,15,18,01,26),78.620003],
                              [new Date(2019,11,15,17,00,30),78.566002],
                              [new Date(2019,11,15,16,00,25),78.314003],
                              [new Date(2019,11,15,15,00,21),78.241997],
                              [new Date(2019,11,15,14,03,24),77.917999],
                              [new Date(2019,11,15,13,01,28),77.269997],
                              [new Date(2019,11,15,12,01,35),77.071999],
                              [new Date(2019,11,15,11,00,24),77.414001],
                              [new Date(2019,11,15,10,00,31),76.963997],
                              [new Date(2019,11,15,09,00,27),76.676003],
                              [new Date(2019,11,15,08,00,25),76.928001],
                              [new Date(2019,11,15,07,00,32),76.837997],
                              [new Date(2019,11,15,06,00,27),76.639999],
                              [new Date(2019,11,15,05,00,30),77.162003],
                              [new Date(2019,11,15,04,01,23),77.216003],
                              [new Date(2019,11,15,03,01,27),78.098000],
                              [new Date(2019,11,15,02,01,26),77.629997],
                              [new Date(2019,11,15,01,02,24),78.188004],
                              [new Date(2019,11,15,00,00,26),77.846001],
                              [new Date(2019,11,14,23,01,25),78.223999],
                              [new Date(2019,11,14,22,00,25),77.972000],
                              [new Date(2019,11,14,21,01,36),78.134003],
                              [new Date(2019,11,14,20,00,28),78.403999],
                              [new Date(2019,11,14,19,01,25),78.223999],
                              [new Date(2019,11,14,18,01,27),77.900002],
                              [new Date(2019,11,14,17,01,28),78.043999],
                              [new Date(2019,11,14,16,01,22),77.720001],
                              [new Date(2019,11,14,15,01,25),77.828003],
                              [new Date(2019,11,14,14,01,26),77.377998],
                              [new Date(2019,11,14,13,01,37),77.269997],
                              [new Date(2019,11,14,12,01,31),76.351997],
                              [new Date(2019,11,14,11,01,33),76.028000],
                              [new Date(2019,11,14,10,01,23),76.136002],
                              [new Date(2019,11,14,09,01,30),75.776001],
                              [new Date(2019,11,14,08,01,51),75.811996],
                              [new Date(2019,11,14,07,01,34),76.351997],
                              [new Date(2019,11,14,06,00,31),75.776001],
                              [new Date(2019,11,14,05,00,29),76.837997],
                              [new Date(2019,11,14,04,00,33),77.125999],
                              [new Date(2019,11,14,03,00,31),76.442001],
                              [new Date(2019,11,14,02,02,28),77.557999],
                              [new Date(2019,11,14,01,01,34),77.737999],
                              [new Date(2019,11,14,00,02,05),76.910004],
                              [new Date(2019,11,13,23,02,04),77.900002],
                              [new Date(2019,11,13,22,02,04),78.061996],
                              [new Date(2019,11,13,21,02,23),77.251999],
                              [new Date(2019,11,13,20,05,30),77.449997],
                              [new Date(2019,11,13,19,04,17),77.162003],
                              [new Date(2019,11,13,18,00,26),77.468002],
                              [new Date(2019,11,13,17,00,31),76.982002],
                              [new Date(2019,11,13,16,00,21),77.197998],
                              [new Date(2019,11,13,15,00,27),77.036003],
                              [new Date(2019,11,13,14,00,04),76.837997],
                              [new Date(2019,11,13,13,02,21),76.748001],
                              [new Date(2019,11,13,12,02,04),75.919998],
                              [new Date(2019,11,13,11,02,25),75.973999],
                              [new Date(2019,11,13,10,08,23),75.830002],
                              [new Date(2019,11,13,09,05,38),76.190002],
                              [new Date(2019,11,13,08,02,38),75.776001],
                              [new Date(2019,11,13,07,08,32),76.171997],
                              [new Date(2019,11,13,06,00,37),75.272003],
                              [new Date(2019,11,13,05,01,31),75.667999],
                              [new Date(2019,11,13,04,01,27),76.820000],
                              [new Date(2019,11,13,03,01,39),76.477997],
                              [new Date(2019,11,13,02,07,43),76.622002],
                              [new Date(2019,11,13,01,01,31),77.000000],
                              [new Date(2019,11,13,00,02,38),77.792000],
                              [new Date(2019,11,12,23,02,29),78.818001],
                              [new Date(2019,11,12,22,00,38),78.295998],
                              [new Date(2019,11,12,21,00,36),78.169998],
                              [new Date(2019,11,12,20,01,28),78.278000],
                              [new Date(2019,11,12,19,01,37),78.169998],
                              [new Date(2019,11,12,18,04,19),77.828003],
                              [new Date(2019,11,12,17,04,16),78.080002],
                              [new Date(2019,11,12,16,01,37),77.702003],
                              [new Date(2019,11,12,15,01,24),77.720001],
                              [new Date(2019,11,12,14,00,30),77.648003],
                              [new Date(2019,11,12,13,12,26),77.000000],
                              [new Date(2019,11,12,12,00,24),77.197998],
                              [new Date(2019,11,12,11,01,33),77.000000],
                              [new Date(2019,11,12,10,01,25),77.737999],
                              [new Date(2019,11,12,09,02,26),78.134003],
                              [new Date(2019,11,12,08,01,32),78.169998],
                              [new Date(2019,11,12,07,04,18),77.737999],
                              [new Date(2019,11,12,06,03,24),77.989998],
                              [new Date(2019,11,12,05,09,37),76.585999],
                              [new Date(2019,11,12,04,03,25),76.694000],
                              [new Date(2019,11,12,03,01,25),77.557999],
                              [new Date(2019,11,12,02,01,28),78.278000],
                              [new Date(2019,11,12,01,02,34),78.872002],
                              [new Date(2019,11,12,00,02,24),79.862000],
                              [new Date(2019,11,11,23,02,26),79.879997],
                              [new Date(2019,11,11,22,02,25),80.150002],
                              [new Date(2019,11,11,21,02,32),79.681999],
                              [new Date(2019,11,11,20,02,37),80.167999],
                              [new Date(2019,11,11,19,56,29),79.970001],
                              [new Date(2019,11,11,07,06,00),78.620003],
                              [new Date(2019,11,11,06,53,09),78.620003],
                              [new Date(2019,11,11,05,12,14),79.267998],
                              [new Date(2019,11,11,02,00,03),79.699997],
                              [new Date(2019,11,11,01,17,10),79.879997],
                              [new Date(2019,11,11,00,00,22),80.078003],
                              [new Date(2019,11,10,23,12,32),80.744003],
                              [new Date(2019,11,10,22,39,22),80.276001],
                              [new Date(2019,11,10,21,09,29),80.239998],
                              [new Date(2019,11,10,20,00,12),79.807999],
                              [new Date(2019,11,10,17,16,08),79.160004],
                              [new Date(2019,11,10,15,32,41),79.015999],
                              [new Date(2019,11,10,09,02,29),77.251999],
                              [new Date(2019,11,10,08,23,25),77.468002],
                              [new Date(2019,11,10,07,46,54),78.889999],
                              [new Date(2019,11,09,22,10,09),78.746002],
                              [new Date(2019,11,09,20,04,26),78.260002],
                              [new Date(2019,11,09,10,09,22),78.655998],
                              [new Date(2019,11,09,09,16,29),79.339996],
                              [new Date(2019,11,09,08,00,24),78.764000],
                              [new Date(2019,11,09,07,51,23),79.106003],
                              [new Date(2019,11,09,06,39,39),78.620003],
                              [new Date(2019,11,09,03,01,17),77.125999],
                              [new Date(2019,11,09,02,58,19),77.180000],
                              [new Date(2019,11,08,21,02,06),78.440002],
                              [new Date(2019,11,08,20,59,00),78.440002],
                              [new Date(2019,11,08,09,37,10),76.820000],
                              [new Date(2019,11,08,08,31,11),77.323997],
                              [new Date(2019,11,08,05,01,26),78.169998],
                              [new Date(2019,11,08,04,25,58),78.620003],
                              [new Date(2019,11,08,03,07,31),78.223999],
                              [new Date(2019,11,08,01,22,11),78.620003],
                              [new Date(2019,11,08,00,00,03),78.440002],
                              [new Date(2019,11,07,23,13,18),78.601997],
                              [new Date(2019,11,07,20,01,20),78.512001],
                              [new Date(2019,11,07,19,39,48),78.494003],
                              [new Date(2019,11,07,14,34,09),77.180000],
                              [new Date(2019,11,07,02,44,41),78.440002],
                              [new Date(2019,11,07,01,05,48),78.314003],
                              [new Date(2019,11,06,23,06,34),79.519997],
                              [new Date(2019,11,06,21,23,04),79.160004],
                              [new Date(2019,11,06,19,20,12),78.169998],
                              [new Date(2019,11,06,17,02,26),77.503998],
                              [new Date(2019,11,06,16,02,36),77.774002],
                              [new Date(2019,11,06,15,56,42),77.540001],
                              [new Date(2019,11,06,10,06,55),74.732002],
                              [new Date(2019,11,06,09,02,02),75.056000],
                              [new Date(2019,11,06,07,07,19),76.351997],
                              [new Date(2019,11,06,06,07,04),77.360001],
                              [new Date(2019,11,06,04,04,13),77.989998],
                              [new Date(2019,11,06,03,43,09),78.620003],
                              [new Date(2019,11,06,01,02,16),80.384003],
                              [new Date(2019,11,06,00,47,35),80.599998],
                              [new Date(2019,11,05,04,05,52),80.708000],
                              [new Date(2019,11,05,03,02,15),81.194000],
                              [new Date(2019,11,05,02,02,27),81.176003],
                              [new Date(2019,11,05,01,20,30),80.816002],
                              [new Date(2019,11,05,00,29,27),81.139999],
                              [new Date(2019,11,04,22,06,39),79.519997],
                              [new Date(2019,11,04,21,18,53),79.519997],
                              [new Date(2019,11,04,20,00,27),79.898003],
                              [new Date(2019,11,04,09,04,10),78.206001],
                              [new Date(2019,11,04,06,10,10),78.620003],
                              [new Date(2019,11,04,03,04,14),78.440002],
                              [new Date(2019,11,04,02,43,27),78.620003],
                              [new Date(2019,11,03,20,56,35),80.599998],
                              [new Date(2019,11,03,19,01,25),78.980003],
                              [new Date(2019,11,03,18,10,05),78.494003],
                              [new Date(2019,11,03,17,01,54),77.792000],
                              [new Date(2019,11,03,08,36,09),75.739998],
                              [new Date(2019,11,03,07,07,08),76.694000],
                              [new Date(2019,11,03,06,42,19),77.360001],
                              [new Date(2019,11,03,05,18,25),80.059998],
                              [new Date(2019,11,03,04,09,08),81.139999],
                              [new Date(2019,11,03,02,04,12),81.806000],
                              [new Date(2019,11,03,00,05,11),81.014000],
                              [new Date(2019,11,02,23,08,17),80.942001],
                              [new Date(2019,11,02,15,12,15),79.160004],
                              [new Date(2019,11,02,14,06,07),79.393997],
                              [new Date(2019,11,02,13,48,07),79.160004],
                              [new Date(2019,11,02,07,18,10),79.519997],
                              [new Date(2019,11,02,06,14,10),78.800003],
                              [new Date(2019,11,02,05,13,49),79.015999],
                              [new Date(2019,11,02,04,25,54),78.620003],
                              [new Date(2019,11,02,03,44,08),78.800003],
                              [new Date(2019,11,02,02,04,38),78.403999],
                              [new Date(2019,11,02,01,58,18),78.440002],
                              [new Date(2019,11,01,23,55,00),78.260002],
                              [new Date(2019,11,01,22,36,03),78.080002],
                              [new Date(2019,11,01,21,14,51),77.972000],
                              [new Date(2019,11,01,18,27,02),78.332001],
                              [new Date(2019,11,01,16,06,10),78.008003],
                              [new Date(2019,11,01,15,54,09),77.720001],
                              [new Date(2019,11,01,13,57,09),77.540001],
                              [new Date(2019,11,01,11,01,27),77.809998],
                              [new Date(2019,11,01,10,01,15),77.503998],
                              [new Date(2019,11,01,09,19,20),77.900002],
                              [new Date(2019,11,01,08,49,05),77.594002],
                              [new Date(2019,11,01,04,18,06),77.792000],
                              [new Date(2019,11,01,03,45,08),77.774002],
                              [new Date(2019,11,01,01,03,30),77.648003],
                              [new Date(2019,11,01,00,04,06),77.882004],
                              [new Date(2019,10,30,23,19,04),77.737999],
                              [new Date(2019,10,30,22,02,07),78.134003],
                              [new Date(2019,10,30,21,59,02),77.900002],
                              [new Date(2019,10,30,15,24,51),77.720001],
                              [new Date(2019,10,30,14,33,23),77.900002],
                              [new Date(2019,10,30,12,37,53),77.720001],
                              [new Date(2019,10,30,09,03,40),77.900002],
                              [new Date(2019,10,30,08,39,40),77.809998],
                              [new Date(2019,10,30,07,04,16),77.468002],
                              [new Date(2019,10,30,06,00,33),77.972000],
                              [new Date(2019,10,30,05,00,45),77.449997],
                              [new Date(2019,10,30,04,30,07),77.720001],
                              [new Date(2019,10,30,02,47,59),78.800003],
                              [new Date(2019,10,29,23,22,07),78.620003],
                              [new Date(2019,10,28,02,00,39),78.620003],
                              [new Date(2019,10,28,00,10,39),78.080002],
                              [new Date(2019,10,27,23,02,12),78.853996],
                              [new Date(2019,10,27,22,19,49),78.332001],
                              [new Date(2019,10,27,04,27,27),76.603996],
                              [new Date(2019,10,27,01,14,04),77.557999],
                              [new Date(2019,10,27,00,13,28),77.575996],
                              [new Date(2019,10,26,23,00,37),77.989998],
                              [new Date(2019,10,26,22,30,58),78.620003],
                              [new Date(2019,10,26,21,06,24),78.241997],
                              [new Date(2019,10,26,20,51,45),77.540001],
                              [new Date(2019,10,26,12,25,28),76.405998],
                              [new Date(2019,10,26,10,30,11),75.919998],
                              [new Date(2019,10,26,04,40,47),76.820000],
                              [new Date(2019,10,26,03,30,33),77.360001],
                              [new Date(2019,10,26,02,01,30),77.234001],
                              [new Date(2019,10,26,00,02,30),76.748001],
                              [new Date(2019,10,25,23,15,25),77.216003],
                              [new Date(2019,10,25,22,01,29),77.720001],
                              [new Date(2019,10,25,21,52,41),77.900002],
                              [new Date(2019,10,24,00,01,53),77.269997]
                              ]);
                              data.sort(
                                        column: 1,
                                        desc: true
                                        );
                              var options = 
                                  legend: 'none',
                                  width: 3300,
                                  height: 500,
                                  options: 
                                      theme: 'maximized'
                                  ,
                                  legend: position: 'none',
                                  interpolateNulls: true,
                                  hAxis: 
                                      format: 'd-MMM'
                                  ,
                                  vAxis: 
                                      format:'#.0°'
                                  ,
                                  'backgroundColor': 'transparent',
                                  <!--                                  axes: -->
                                      <!--                                      x: -->
                                          <!--                                          0: side: 'bottom'-->
                                          <!--                                      -->
                                      <!--                                  -->
                              ;

                              var chart = new google.charts.Line(document.getElementById('line_top_x'));

                              chart.draw(data, google.charts.Line.convertOptions(options));

            
        </script>
    </head>
    <body>
        <div id="line_top_x"></div>
    </body>
</html>

我是否缺少任何东西或需要添加任何东西?

-谢谢。亚基尔

答案

具有连续轴(日期,数字等)的图表在绘制之前会自动排序。

因此您必须使用hAxis.direction来颠倒顺序。

但是,material图表不支持direction配置选项。

hAxis,vAxis,hAxes.*,vAxes.*.direction

包括其他几个,参见-> Tracking Issue for Material Chart Feature Parity

相反,您可以使用经典图表...

材料 = google.charts.Line-包装:'line'

经典 = google.visualization.LineChart-包:'corechart'

请参阅以下工作片段...

google.charts.load('current', 
  packages: ['corechart']
).then(function () 
  var data = new google.visualization.DataTable();
  data.addColumn('datetime', '');
  data.addColumn('number', 'Temperature');
  data.addRows([
    [new Date(2019,11,17,23,00,22),78.332001],
    [new Date(2019,11,17,22,00,15),78.332001],
    [new Date(2019,11,17,21,02,29),78.458000],
    [new Date(2019,11,17,20,04,18),77.594002],
    [new Date(2019,11,17,19,01,14),76.765999],
    [new Date(2019,11,17,18,02,20),76.622002],
    [new Date(2019,11,17,17,02,14),76.477997],
    [new Date(2019,11,17,16,02,12),76.514000],
    [new Date(2019,11,17,15,02,17),76.334000],
    [new Date(2019,11,17,14,02,15),76.136002],
    [new Date(2019,11,17,13,02,15),76.028000],
    [new Date(2019,11,17,12,02,13),75.578003],
    [new Date(2019,11,17,11,02,14),75.685997],
    [new Date(2019,11,17,10,02,14),75.722000],
    [new Date(2019,11,17,09,02,16),75.811996],
    [new Date(2019,11,17,08,01,14),76.117996],
    [new Date(2019,11,17,07,01,16),76.550003],
    [new Date(2019,11,17,06,02,13),77.108002],
    [new Date(2019,11,17,05,02,12),77.846001],
    [new Date(2019,11,17,04,00,16),77.900002],
    [new Date(2019,11,17,03,00,16),78.134003],
    [new Date(2019,11,17,02,00,15),77.431999],
    [new Date(2019,11,17,01,00,13),78.061996],
    [new Date(2019,11,17,00,00,11),77.683998],
    [new Date(2019,11,16,23,00,13),77.954002],
    [new Date(2019,11,16,22,00,12),78.098000],
    [new Date(2019,11,16,21,00,14),77.612000],
    [new Date(2019,11,16,20,02,15),77.594002],
    [new Date(2019,11,16,19,02,31),76.783997],
    [new Date(2019,11,16,18,02,42),76.783997],
    [new Date(2019,11,16,17,02,33),76.837997],
    [new Date(2019,11,16,16,08,40),76.783997],
    [new Date(2019,11,16,15,02,22),76.820000],
    [new Date(2019,11,16,14,02,32),76.874001],
    [new Date(2019,11,16,13,02,34),77.288002],
    [new Date(2019,11,16,12,02,37),77.360001],
    [new Date(2019,11,16,11,02,40),78.206001],
    [new Date(2019,11,16,10,02,46),77.648003],
    [new Date(2019,11,16,09,02,33),78.295998],
    [new Date(2019,11,16,08,02,42),78.026001],
    [new Date(2019,11,16,07,02,25),77.648003],
    [new Date(2019,11,16,06,05,30),78.043999],
    [new Date(2019,11,16,05,02,35),77.468002],
    [new Date(2019,11,16,04,00,44),77.720001],
    [new Date(2019,11,16,03,00,28),76.514000],
    [new Date(2019,11,16,02,00,31),76.982002],
    [new Date(2019,11,16,01,00,35),78.043999],
    [new Date(2019,11,16,00,01,27),77.989998],
    [new Date(2019,11,15,23,01,30),78.889999],
    [new Date(2019,11,15,22,01,22),78.800003],
    [new Date(2019,11,15,21,01,47),78.835999],
    [new Date(2019,11,15,20,01,33),78.800003],
    [new Date(2019,11,15,19,01,26),78.620003],
    [new Date(2019,11,15,18,01,26),78.620003],
    [new Date(2019,11,15,17,00,30),78.566002],
    [new Date(2019,11,15,16,00,25),78.314003],
    [new Date(2019,11,15,15,00,21),78.241997],
    [new Date(2019,11,15,14,03,24),77.917999],
    [new Date(2019,11,15,13,01,28),77.269997],
    [new Date(2019,11,15,12,01,35),77.071999],
    [new Date(2019,11,15,11,00,24),77.414001],
    [new Date(2019,11,15,10,00,31),76.963997],
    [new Date(2019,11,15,09,00,27),76.676003],
    [new Date(2019,11,15,08,00,25),76.928001],
    [new Date(2019,11,15,07,00,32),76.837997],
    [new Date(2019,11,15,06,00,27),76.639999],
    [new Date(2019,11,15,05,00,30),77.162003],
    [new Date(2019,11,15,04,01,23),77.216003],
    [new Date(2019,11,15,03,01,27),78.098000],
    [new Date(2019,11,15,02,01,26),77.629997],
    [new Date(2019,11,15,01,02,24),78.188004],
    [new Date(2019,11,15,00,00,26),77.846001],
    [new Date(2019,11,14,23,01,25),78.223999],
    [new Date(2019,11,14,22,00,25),77.972000],
    [new Date(2019,11,14,21,01,36),78.134003],
    [new Date(2019,11,14,20,00,28),78.403999],
    [new Date(2019,11,14,19,01,25),78.223999],
    [new Date(2019,11,14,18,01,27),77.900002],
    [new Date(2019,11,14,17,01,28),78.043999],
    [new Date(2019,11,14,16,01,22),77.720001],
    [new Date(2019,11,14,15,01,25),77.828003],
    [new Date(2019,11,14,14,01,26),77.377998],
    [new Date(2019,11,14,13,01,37),77.269997],
    [new Date(2019,11,14,12,01,31),76.351997],
    [new Date(2019,11,14,11,01,33),76.028000],
    [new Date(2019,11,14,10,01,23),76.136002],
    [new Date(2019,11,14,09,01,30),75.776001],
    [new Date(2019,11,14,08,01,51),75.811996],
    [new Date(2019,11,14,07,01,34),76.351997],
    [new Date(2019,11,14,06,00,31),75.776001],
    [new Date(2019,11,14,05,00,29),76.837997],
    [new Date(2019,11,14,04,00,33),77.125999],
    [new Date(2019,11,14,03,00,31),76.442001],
    [new Date(2019,11,14,02,02,28),77.557999],
    [new Date(2019,11,14,01,01,34),77.737999],
    [new Date(2019,11,14,00,02,05),76.910004],
    [new Date(2019,11,13,23,02,04),77.900002],
    [new Date(2019,11,13,22,02,04),78.061996],
    [new Date(2019,11,13,21,02,23),77.251999],
    [new Date(2019,11,13,20,05,30),77.449997],
    [new Date(2019,11,13,19,04,17),77.162003],
    [new Date(2019,11,13,18,00,26),77.468002],
    [new Date(2019,11,13,17,00,31),76.982002],
    [new Date(2019,11,13,16,00,21),77.197998],
    [new Date(2019,11,13,15,00,27),77.036003],
    [new Date(2019,11,13,14,00,04),76.837997],
    [new Date(2019,11,13,13,02,21),76.748001],
    [new Date(2019,11,13,12,02,04),75.919998],
    [new Date(2019,11,13,11,02,25),75.973999],
    [new Date(2019,11,13,10,08,23),75.830002],
    [new Date(2019,11,13,09,05,38),76.190002],
    [new Date(2019,11,13,08,02,38),75.776001],
    [new Date(2019,11,13,07,08,32),76.171997],
    [new Date(2019,11,13,06,00,37),75.272003],
    [new Date(2019,11,13,05,01,31),75.667999],
    [new Date(2019,11,13,04,01,27),76.820000],
    [new Date(2019,11,13,03,01,39),76.477997],
    [new Date(2019,11,13,02,07,43),76.622002],
    [new Date(2019,11,13,01,01,31),77.000000],
    [new Date(2019,11,13,00,02,38),77.792000],
    [new Date(2019,11,12,23,02,29),78.818001],
    [new Date(2019,11,12,22,00,38),78.295998],
    [new Date(2019,11,12,21,00,36),78.169998],
    [new Date(2019,11,12,20,01,28),78.278000],
    [new Date(2019,11,12,19,01,37),78.169998],
    [new Date(2019,11,12,18,04,19),77.828003],
    [new Date(2019,11,12,17,04,16),78.080002],
    [new Date(2019,11,12,16,01,37),77.702003],
    [new Date(2019,11,12,15,01,24),77.720001],
    [new Date(2019,11,12,14,00,30),77.648003],
    [new Date(2019,11,12,13,12,26),77.000000],
    [new Date(2019,11,12,12,00,24),77.197998],
    [new Date(2019,11,12,11,01,33),77.000000],
    [new Date(2019,11,12,10,

以上是关于X轴的Google Live图形值按降序排列的主要内容,如果未能解决你的问题,请参考以下文章

Ruby - 按值按降序排序哈希值

将字典值按降序排序[重复]

如何根据特定值按降序对数组进行排序[重复]

如何按值按降序对哈希进行排序并在 ruby​​ 中输出哈希?

根据值按降序对 Map<Key,Value> 进行排序 [重复]

获取列表中出现的值,并按降序进行排列