Radial Line Chart

The Ignite UI for Web Components radial line chart belongs to a group of radial charts and is rendered using a collection of straight lines connecting data points. The IgcRadialLineSeriesComponent uses the same concepts of data plotting as the IgcLineSeriesComponent, but wraps data points around a circle rather than stretching them along a horizontal line.

Demo

Required Axes

The Web Components data chart component provides various types of axes but only the following types of axes can be used with IgcRadialLineSeriesComponent.

Required Data

The IgcRadialLineSeriesComponent has the following data requirements:

  • The data source must be an array or a list of data items.
  • The data source must contain at least one data item otherwise the chart will not render the IgcRadialLineSeriesComponent.
  • All data items must contain at least one label data column (string or date time) which should be mapped to the Label property of the category axis (e.g. IgcCategoryAngleAxisComponent).
  • All data items must contain at least one numeric data column which should be mapped using the valueMemberPath property of the IgcRadialLineSeriesComponent.

You can use the SampleRadialData as data source which meets above data requirements.

public dataSource: any[] = SampleRadialData.create();

Required Modules

Creation of the IgcRadialLineSeriesComponent requires the following modules:

import { IgcDataChartComponent } from 'igniteui-webcomponents-charts';
import { IgcDataChartCoreModule } from 'igniteui-webcomponents-charts';
import { IgcDataChartRadialCoreModule } from 'igniteui-webcomponents-charts';
import { IgcDataChartRadialModule } from 'igniteui-webcomponents-charts';
import { IgcDataChartInteractivityModule } from 'igniteui-webcomponents-charts';
import { ModuleManager } from 'igniteui-webcomponents-core';

ModuleManager.register(
    IgcDataChartCoreModule,
    IgcDataChartRadialCoreModule,
    IgcDataChartRadialModule,
    IgcDataChartInteractivityModule
);

Code Example

This code demonstrates how to create an instance of the Ignite UI for Web Components data chart with IgcRadialLineSeriesComponent and bind it to a data source.

<igc-data-chart id="chart"
    width="100%"
    height="100%">
    <igc-category-angle-axis name="angleAxis" label="Department">
    </igc-category-angle-axis>
    <igc-numeric-radius-axis name="radiusAxis"
    inner-radius-extent-scale="0.1" minimum-value="0">
    </igc-numeric-radius-axis>
    <igc-radial-line-series
        name="series1"
        value-member-path="Budget"
        value-axis-name="radiusAxis"
        angle-axis-name="angleAxis"
        title="Budget">
    </igc-radial-line-series>
    <igc-radial-line-series
        name="series2"
        value-member-path="Spending"
        value-axis-name="radiusAxis"
        angle-axis-name="angleAxis"
        title="Spending">
    </igc-radial-line-series>
</igc-data-chart>
this.chart = document.getElementById("chart") as IgcDataChartComponent;
this.chart.dataSource = SampleRadialData.create();

Additional Resources