Skip to content

Infragistics Community Forum / Web / Ignite UI for Angular / igx-data-chart always highlight specific data points

igx-data-chart always highlight specific data points

New Discussion
Hariharan S
Hariharan S asked on Jan 29, 2025 5:12 PM

Is this possible to highlight specific data points as shown below (drawn in red) ?

Sign In to post a reply

Replies

  • 0
    Hariharan S
    Hariharan S answered on Jan 29, 2025 3:14 PM

  • 3
    Michael DiFilippo
    Michael DiFilippo answered on Jan 29, 2025 5:12 PM Verified

    Hello and thank you for contacting Infragistics. I attached a sample on how to achieve chart selection, a newer feature. Apologies, we have documentation but our table of contents needs to make this accessible.

    [View:/community/cfs-file/__key/communityserver-discussions-components-files/1043/type_2D00_category_2D00_series.zip:320:240]

    You can access the topic here until our website is updated accordingly:

    https://www.infragistics.com/products/ignite-ui-angular/angular/components/charts/features/chart-data-selection#programmatic-selection

    Chart selection will look like this:

            <igx-data-chart #chart
            isHorizontalZoomEnabled="true"
            isVerticalZoomEnabled="true"
            width="100%"
            height="100%"
            [dataSource]="data"
            selectionMode="SelectionColorFill"
            selectionBehavior="Auto"
            selectionBrush="Red">
            public data = [

            { Year: “1996”, USA: 148, CHN: 110, RUS: 95},
            { Year: “2000”, USA: 142, CHN: 115, RUS: 91},
            { Year: “2004”, USA: 134, CHN: 121, RUS: 86},
            { Year: “2008”, USA: 131, CHN: 129, RUS: 65},
            { Year: “2012”, USA: 135, CHN: 115, RUS: 77},
            { Year: “2016”, USA: 146, CHN: 112, RUS: 88}
            ];
               let matcher: IgxSeriesMatcher = new IgxSeriesMatcher();

                let selection: IgxChartSelection = new IgxChartSelection();
                selection.item = data[1];  
                matcher.memberPath = "USA";
                matcher.memberPathType = "ValueMemberPath";
                selection.matcher = matcher;
       
                chart.selectedSeriesItems.add(selection);
  • You must be logged in to reply to this topic.
Discussion created by
Favorites
Replies
Created On
Last Post
Discussion created by
Hariharan S
Favorites
0
Replies
2
Created On
Jan 29, 2025
Last Post
1 year ago

Suggested Discussions

Created by

Created on

Jan 29, 2025 5:12 PM

Last activity on

Jan 14, 2026 2:49 PM