Skip to main content

All Questions

Tagged with
0 votes
1 answer
48 views

How to Display Values Next to Legend in React Pie Chart? Getting 'Undefined' Error

I am trying to display value next to legend, but I am getting undefined. Debugged but no luck, can you let me know how to fix it. Providing my code snippet and stackblitz below https://stackblitz.com/...
Ram01's user avatar
  • 171
-1 votes
1 answer
72 views

How to separate legend and chart when having three chart

i have 3 pie charts which have legend in below but in first pie charts there are 10 legend and in second there are only 4 legend then when i give padding to chart to adjust the 10 legend then in ...
Amit Thelkar's user avatar
0 votes
0 answers
25 views

How can we change the position of legend using highcharts?

I am building a pie chart with highcharts js, but having a problem. As shown below, I was able to put the legend on the bottom, but it's not aligned with the chart. I am trying to put the legend at ...
SuWon's user avatar
  • 23
0 votes
0 answers
502 views

How to move label text of pie chart to newline in chartjs

import React from 'react'; import { Chart as ChartJS,ChartOptions, ArcElement, Tooltip, Legend } from 'chart.js'; import { Pie } from 'react-chartjs-2'; import { Box } from '@mui/material'; ChartJS....
Bhupendra Basera's user avatar
1 vote
1 answer
53 views

how to avoid over lapping legends and pie chart [duplicate]

I am trying to draw a pie chart using python matplotlib. How to position the legend and pie chart so they are not overlapping each other. My code is as below: import matplotlib.pyplot as plt import ...
PChao's user avatar
  • 429
0 votes
1 answer
80 views

Amchart 4 Legend In Arabic not Showing Properly

I want To start the Legend marker from the right side I already used these three Properties. chart.legend.reverseOrder = true; chart.legend.itemContainers.template.reverseOrder = true;chart.rtl = true;...
wajiha siddiqui's user avatar
1 vote
1 answer
44 views

How to remove one legend option for Semi circle donut?

I need to leave just one legend option for this chart. enter image description here My code: series: [{ name: 'Brands', innerSize: '60%', colorByPoint: true, ...
Artem Shakun's user avatar
0 votes
2 answers
111 views

Pie chart legend with multiple lines of text in R

I am attempting to use the following code to split my long line of text into multiple lines in the legend of a pie chart. The current code creates a legend with a lot of white space and the text runs ...
Hannah Harder's user avatar
0 votes
0 answers
210 views

How to map colors from multiple matplotlib subplot pie charts to a single figure legend

So I have been trying to get a legend working for a figure with multiple subplots that contain pie charts. The pie charts can contain any number of manufactures from a set list of manufacturers, but ...
Kgrover3's user avatar
0 votes
1 answer
2k views

How to align legend along with pie chart?

I'm new to apache echarts and would like to know how to solve this problem. At lower resolutions the pie chart legend overlaps the chart, is there any way to freeze the legend or an auto adjust so ...
Felipe Jardim's user avatar
0 votes
2 answers
739 views

Arrange legends plotly

I want to arrange the legend for my pie chart which I have built using plotly, by default it arranges the legend having the highest distribution first and with lower distribution after it, but i want ...
Abhishek Mishra's user avatar
3 votes
0 answers
331 views

How to get R Plotly pie charts to show legends based on values other than labels

I am plotting a pie chart with R plotly which I want to slice the pie based on column A and color each slice based on column B. I want each slice to show label based on column A, and I want the ...
Bernard's user avatar
  • 73
0 votes
1 answer
915 views

Chartjs Custom Legend for Doughnut Chart Having Labelled Lines Sticking Out of Each Section

I know how to draw doughnut chart for a data set in Chartjs and its legend customization but I want to have a chart like the one shown in the image below in which lines from each section sticking out ...
M. Ismail's user avatar
  • 371
3 votes
1 answer
13k views

How to change legend order of Pie Chart in PowerBi

As for piechart in powerBi, currently legend order is set by value. I want to reorder it by alphabet order of legend key. I select specified key (IsReady) and flags and show below graph. Here is my ...
vector's user avatar
  • 53
0 votes
1 answer
1k views

Add values to pie chart legend with ggplot2 in R

I have created a pie chart with ggplot in R plotting "Amounts" for 7 companies (A to G). The data and code are the following: # Data data=data.frame('Company'=(c("A","B",&...
Elsa's user avatar
  • 49
1 vote
3 answers
3k views

Adding legend to pie chart that is wrapped by ggplot

I am quite new with R and require some support with using the pie function. I need to return a ggplot so I have wrapped the pie function with this. The output is a pie chart as expected, only problem ...
user avatar
0 votes
0 answers
54 views

Fix a pie-chart plot to make it more readable by adding a Legend

I need to fix the following pie chart, I need a legend with the names of the countries (percentages can be fine like this. COMP_plot <- comp_plot %>% select(-commodity) %>% ...
Andrea Dalla Rosa's user avatar
1 vote
1 answer
665 views

legend not visible in d3.js pie chart

I am trying to add legend to pie chart. I can see the legend element added in the inspect element but I am not able to see it. Could it be due to background color ? I looked into other questions but I ...
user2390751's user avatar
1 vote
2 answers
485 views

R plot_ly pieplot legend with different column

I have this data frame for buiding a pie plot with plot_ly() function: piedat <- data.frame("phylum" = c("Non-classified genera", "Genera with RA < 1%", "Firmicutes", "Fibrobacteres", "...
ALG's user avatar
  • 192
1 vote
0 answers
269 views

How do I adjust the labels for my pie chart

I am creating a pie chart to show the percentages of property types available in a dataset in the column ["PTypes"]. I used the code below `import matplotlib.pyplot as plt # Pie chart df['...
Brytedata's user avatar
3 votes
1 answer
3k views

Arrange 4 plotly pie graphs in R

I have four separate pie graphs all with the same specified color scheme (the code is identical apart from the dataframe). The colors are designated because I want to combine them in the 4 grid ...
user avatar
0 votes
1 answer
177 views

Creating a pie chart with unknown number of pies

I am trying to create function which creates a pie chart. This pie chart can have n number of pies that's why I am taking function arguments as *args. I found a way to create colors according to the ...
Anudocs's user avatar
  • 686
0 votes
1 answer
397 views

D3 pie chart legends with horizontal pagination

I have a requirement where i need to show pagination for legends if the number of legends is more than two. I am using d3 pie chart. Any help would be appreciated. I have found out something similar ...
Amir's user avatar
  • 113
2 votes
0 answers
69 views

R: Legend position is c(1,0.5), but it is still inside my chart. How can I move it outside without it beeing cut off

I am plotting and saving a pie Chart and want the legend to be closer to the chart than with no position specification. When using This puts the legend inside my pie and when moving the legend even ...
Katsuyo's user avatar
  • 73
3 votes
0 answers
2k views

Show only top 5 values in legend for Pie Chart (Am4 charts)

I have a pie chart with legends made using Am4 charts but I need to display only the top 5 legend values. I wrote the following code: var chart = am4core.create("chartdiv2", am4charts.PieChart); ...
Thanatos's user avatar
  • 292
6 votes
1 answer
3k views

Remove space between name and percentage in pie chart legend (amcharts4)

I want to get rid of that space in the legend between the name and the percentage. In the pic, I have highlighted the space in yellow. For example, I want the first legend item to be "Lithuania (30....
Thanatos's user avatar
  • 292
4 votes
2 answers
629 views

Matlab; Pie chart with 2+ / split legends R2017b

I'm creating a pie chart and ideally want the legend to be displayed horizontally at the top and/or bottom. However, in almost all cases this isn't possible as the legend go off the figure. Therefore, ...
Steve's user avatar
  • 634
1 vote
1 answer
588 views

I want to remove 1/5 and show all legends in google pie chart

Here i have total 10 legends, but i want to show all 10 legends.
Gaurav Bhalani's user avatar
6 votes
2 answers
30k views

How to create legend position in pie chart.js?

i am using chart js for developing my pie chart. i want to create the legend position just like this. anyone please help me to solve this... here is my code... i actually want the result just like ...
trubex's user avatar
  • 139
2 votes
1 answer
928 views

Pie chart legend not showing - Uncaught TypeError: Cannot set property 'innerHTML' of null

I have to show legends for a pie chart. I have been following below link. http://jsfiddle.net/vrwjfg9z/ But it does not work for me in below code. <!DOCTYPE html> <html> <...
javascript_learner's user avatar

15 30 50 per page