Version

Polar Area Series

This topic explains, with code examples, how to use Polar Area Series in the UltraDataChart™ control.

Introduction

Polar Area Series has a shape of a filled polygon which vertices or corners are located at the polar (angle/radius) coordinates of data points. The PolarAreaSeries uses the same concepts of data plotting as the ScatterSeries but wraps data points around a circle rather than stretching them along a horizontal line. Like with other series types, multiple PolarAreaSeries can be plotted in the same data chart and they can be overlaid on each other to show differences and similarities between data sets. For more information on this group of series, refer to the Radial Series topic.

Preview

Figure 1 demonstrates what Polar Area Series looks like when plotted in the UltraDataChart control.

xamDataChart Polar Area Series 01.png

Figure 1: Sample implementation of a PolarAreaSeries

Data Binding

The code snippet below shows how to bind sample polar data (which is available for download from the Sample Polar Data resource) to the PolarAreaSeries. The example assumes that you have already configured your project for the UltraDataChart control.

In C#:

var data = new PolarDataSource();
var AngleAxis = new NumericYAxis();
var RadiusAxis = new CategoryXAxis();

var series = new PolarAreaSeries();
series.DataSource = data;
series.AngleMemberPath = "Angle";
series.RadiusMemberPath = "Radius";
series.AngleAxis = AngleAxis;
series.RadiusAxis = RadiusAxis;

var chart = new UltraDataChart();
chart.Axes.Add(AngleAxis);
chart.Axes.Add(RadiusAxis);
chart.Series.Add(series);

In Visual Basic:

Dim data As New PolarDataSource()
Dim AngleAxis As New NumericAngleAxis()
Dim RadiusAxis As New NumericRadiusAxis()

Dim series As New PolarAreaSeries()
series.ItemsSource = polarDataSample
series.AngleMemberPath = "Angle"
series.RadiusMemberPath = "Radius"
series.AngleAxis = AngleAxis
series.RadiusAxis = RadiusAxis;

Dim chart As New UltraDataChart()
chart.Axes.Add(AngleAxis)
chart.Axes.Add(RadiusAxis)
chart.Series.Add(series)