0

谷歌饼图

我正在使用 Google 饼图显示信息,但缺少一个标签,增加高度也不起作用。

这是我的代码

var view = new google.visualization.DataView(data);

      view.setColumns([0, 1,
                       { calc: "stringify",
                         sourceColumn: 1,
                         type: "string",
                         role: "annotation" },

                       2]);

      var options = 
      {
        title: "",
    pieSliceText: "none",
    colors: ['#6f9643','#dcc591','#9487bf','#6f9693','#9d5434','#bfe1e0',
                '#a8c08e','#a89fca','#efbfbf','#9fc4d6','#eaaa7a','#dcc591'],
        bar: {groupWidth: "80%"},
        legend: {   
        position: "labeled", 
        textStyle:{bold:true, fontSize: 11}
        },
        height: 500,
        width: 900,
        chartArea:{width:'85%',height:'80%'},
    backgroundColor: { fill:'transparent' },
        is3D:true
      };    

提前致谢!

4

1 回答 1

0

删除这个

pieSliceText: "none"

在饼图中查看标签

更多信息访问

于 2020-11-30T05:21:20.257 回答