question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Access % share of points in pie chart labels

See original GitHub issue

In LiveCharts v1 I could access the share of a value in the piechart through the Participation attribute in the formatter function. I could not find an equivalent in v2 yet. It would be great to add this again to show the % AND the absolute values as well as decide to not show the labels on a pie chart if the share is under a specific %.

This is an example of what worked in v1: Func<ChartPoint, string> labelPoint = chartPoint => chartPoint.Participation > 0.03 ? string.Format("{0:N} ({1:P}), {2}", chartPoint.Y, chartPoint.Participation, chartPoint.SeriesView.Title) : "";

Issue Analytics

  • State:closed
  • Created a year ago
  • Reactions:1
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
korneliuscodecommented, Jul 31, 2023

It’s a stacked bar chart and not every point has all the values. I could share some sample later.

1reaction
beto-rodriguezcommented, Jul 14, 2022

Thanks, this was missing, it is now supported with the referenced commit and will be included in the next version of the library.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Add or remove data labels in a chart
The label options that are available depend on the chart type of your chart. For example, in a pie chart, data labels can...
Read more >
Display data point labels outside a pie chart in a paginated ...
On the design surface, right-click on the chart and select Show Data Labels. To display data point labels outside a pie chart. Create...
Read more >
Display Percent of Total in Queries, Pie Charts in Microsoft ...
I cannot figure out for the life of me how to see a percentage value for the data label. I can do it...
Read more >
MS Access - Can't Get Pie Chart Labels in a Report
I have made a new pie chart using older pie charts as templates, but I just cannot get count labels on my chart...
Read more >
How to make a pie chart in Excel
Right click any slice on your chart, and select Format Data Labels… in the context menu. On the Format Data Labels pane, select...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found