using System.Linq; using LiveCharts; using LiveCharts.Configurations; namespace Wpf.PieChart.DropDowns { public class DropDownPoint { static DropDownPoint() { //In this case we are plotting our own point to have //more control over the current plot //configuring a custom type is quite simple //first we define a mapper var mapper = Mappers.Pie() .Value(x => x.Value);//use the value property in the plot //then we save the mapper globally, there are many ways //so configure a series, for more info see: //https://lvcharts.net/App/examples/v1/wpf/Types%20and%20Configuration Charting.For(mapper); } /// /// Gets or sets the value to plot /// /// /// The value. /// public double Value { get { return Content.Sum(); } } /// /// Gets or sets the content, all the values that represent this point /// /// /// The content. /// public double[] Content { get; set; } /// /// Gets or sets the title. /// /// /// The title. /// public double Title { get; set; } } }