Bunifu polar chart is a circular graph which display a two-dimensional data series in polar coordinates. The x values states the category of data which are automatically created in an angle while the y value defines the distance of the data points from the center of the graph, with the center of the graph usually starting at 0. It is a form of graph that allows a visual comparison between several quantitative or qualitative aspects of a situation.
This section explains you the steps required to start creating a simple bar chart and demonstrate the basic usage of the chart control.
Step 1: Drag the canvas control to the form from the toolbox. In the property section set both XAxesGridLines and YAxesGridlines properties to have a false value
Step 2: From the toolbox drag and drop the Bunifu Polar component to the form
Step 3: Add data to the Polar component as demonstrated in quick tips
Step 4: On the target property of the Polar component select bunifuCanvas1 as the target component
Step 5: Run the application
void renderPolarChart(){Bunifu.Charts.WinForms.ChartTypes.BunifuPolarAreaChart bunifuPolarChart = new Bunifu.Charts.WinForms.ChartTypes.BunifuPolarAreaChart();/** For this example we will use random numbers*/var r = new Random();/** Add your data from your source - accepts double list* Below is an example from a random number*/List<double> data = new List<double>();for (int i = 0; i < 5; i++){data.Add(r.NextDouble());}/** Set your data*/bunifuPolarChart.Data = data;/** Specify the target canvas*/bunifuPolarChart.TargetCanvas = bunifuChartCanvas1;/** Hide grid lines*/bunifuChartCanvas1.XAxesGridLines = false;bunifuChartCanvas1.YAxesGridLines = false;/** Add labels to your canvas* Label count should correspond to data count for charts like Bar charts*/bunifuChartCanvas1.Labels = new string[] { "Label1", "Label2", "Label3", "Label4", "Label5" };/** Beautify the chart by sepcifying the colors* Color count should correspond to data count*/List<Color> bgColors = new List<Color>();for (int i = 0; i < data.Count; i++){bgColors.Add(Color.FromArgb(r.Next(256), r.Next(256), r.Next(256)));}bunifuPolarChart.BackgroundColor = bgColors;}
Private Sub renderPolarChart()Dim bunifuPolarChart As Bunifu.Charts.WinForms.ChartTypes.BunifuPolarAreaChart = New Bunifu.Charts.WinForms.ChartTypes.BunifuPolarAreaChart()'' For this example we will use random numbers'Dim r = New Random()'' Add your data from your source - accepts double list' Below is an example from a random number'Dim data As List(Of Double) = New List(Of Double)()For i As Integer = 0 To 5 - 1data.Add(r.NextDouble())Next'' Set your data'bunifuPolarChart.Data = data'' Specify the target canvas'bunifuPolarChart.TargetCanvas = bunifuChartCanvas1'' Hide grid lines'bunifuChartCanvas1.XAxesGridLines = FalsebunifuChartCanvas1.YAxesGridLines = False'' Add labels to your canvas' Label count should correspond to data count for charts like Bar charts'bunifuChartCanvas1.Labels = New String() {"Label1", "Label2", "Label3", "Label4", "Label5"}'' Beautify the chart by sepcifying the colors' Color count should correspond to data count'Dim bgColors As List(Of Color) = New List(Of Color)()For i As Integer = 0 To data.Count - 1bgColors.Add(Color.FromArgb(r.[Next](256), r.[Next](256), r.[Next](256)))NextbunifuPolarChart.BackgroundColor = bgColorsEnd Sub
BackgroundColor
Gets and sets a color value property to the polar segment background
BorderColor
Gets and sets a color value property to the polar segment borders
BorderWidth
Gets and sets an integer value that can modify the width of the polar segment border.
HoverBackgroundColor
Gets and sets a color value property to apply on the polar background in the event of a mouse hover on a polar segment.
HoverBorderColor
Gets and sets a color value property to apply on the bar’s border in the event of a mouse hover on a polar segment.
HoverBorderWidth
Gets and sets an integer value that can modify the width of the bar’s border when the mouse hovers on a polar segment.
Gets and sets the canvas that will render Bunifu polar chart
Gets and sets an array of numbers as the datasets for Bunifu polar chart
Gets and sets the text to draw on the chart’s legend