weixin_33721344 2016-04-26 01:24 采纳率: 0%
浏览 26

高图:带有JSON的图

As you could pass the following values to a Highcharts graph :

{"titulos": [{"title": "Proveedor"}, {"title": "Total"}], "data": [["Dolex - 9028382372873", 88.59], ["BIOCLEAN - 2093029302930", 2.8]]}

http://www.highcharts.com/

  • 写回答

1条回答 默认 最新

  • weixin_33734785 2016-04-27 12:12
    关注

    Let's try: http://jsfiddle.net/w02p4cru/

      $('#container').highcharts({
        "titulos": [{
          "title": "Proveedor"
        }, {
          "title": "Total"
        }],
        "data": [
          ["Dolex - 9028382372873", 88.59],
          ["BIOCLEAN - 2093029302930", 2.8]
        ]
      });
    

    Turns out that you can, but I guess that is not the desired chart that you will get, since really there won't be anything. Chart's option doesn't match required options format explained in Docs nor API.

    If you change your options to match requirements, then your chart will look like in this demo: http://jsfiddle.net/w02p4cru/1/

    Code:

      $('#container').highcharts({
        "title": {
          "text": "Proveedor"
        },
        "subtitle": {
          "text": "Total"
        },
        "series": [{
          "data": [
            ["Dolex - 9028382372873", 88.59],
            ["BIOCLEAN - 2093029302930", 2.8]
          ]
        }]
      });
    

    This might not be the chart you are looking for because you have not explained what exactly do you need, but general idea is to use required options format.

    评论

报告相同问题?

悬赏问题

  • ¥20 西门子S7-Graph,S7-300,梯形图
  • ¥50 用易语言http 访问不了网页
  • ¥50 safari浏览器fetch提交数据后数据丢失问题
  • ¥15 matlab不知道怎么改,求解答!!
  • ¥15 永磁直线电机的电流环pi调不出来
  • ¥15 用stata实现聚类的代码
  • ¥15 请问paddlehub能支持移动端开发吗?在Android studio上该如何部署?
  • ¥20 docker里部署springboot项目,访问不到扬声器
  • ¥15 netty整合springboot之后自动重连失效
  • ¥15 悬赏!微信开发者工具报错,求帮改