Example of undefined in Angular Chart Component

This sample visualizes the annual mean rainfall in Australia with multi-colored line series in the chart. Data points are enhanced with segments and tooltips.

Annual Mean Precipitation in the United States (1895-2025)Source: ncei.noaa.gov
Description

In this example, you can see how to render and configure the points in a particular range by using MultiColoredLine series. Points under the range can be configured with color and dashArray properties in the ChartSegment.

Tooltips are enabled in this example. To see a tooltip in action, hover over or tap on the chart.

Injecting Module

Chart component features are segregated into individual feature-wise modules. To use multi colored line series feature, we need to inject MultiColoredLineSeriesService into the @NgModule.providers section.

More information about the line series can be found in this documentation section.