Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Hide the labels in the pie graph in echart by baidu

I am referring to this https://ecomfe.github.io/echarts/doc/example/pie1.html#-en example. I am not able to hide the adjacent labels in the pie graph. I have encircled one of the labels I wish to hide in the attached image. Kindly help. Thanks!

enter image description here

like image 518
d33a Avatar asked Jul 20 '16 04:07

d33a


People also ask

How do you put labels on a pie chart?

Add Labels to the Chart To add labels, right-click on any slice in the pie, then click Add Data Labels, in the popup menu.

Is Echarts free to use?

Is ECharts free to use? Yes, ECharts is open-sourced under Apache License 2.0.


1 Answers

Found the solution to my problem. I had to include the following code into the options and it worked:

itemStyle : {
              normal : {
                         label : {
                                   show : false
                                  },
                         labelLine : {
                                       show : false
                                      }
                         }
              }
like image 54
d33a Avatar answered Sep 25 '22 09:09

d33a