Skip to main content
All docs
V25.1
  • Data Analysis Filters

    • 3 minutes to read

    The GridControl allows you to apply Data Analysis Filters - numerical filters that do not have corresponding comparison operators.

    Overview

    The following data analysis filters are available:

    Top / Bottom N

    Displays a specific number of topmost/bottom-most values. You can specify this number as an absolute or percentage value.

    Above / Below Average

    Displays values that are above/below an average value.

    Unique / Duplicate

    Displays unique/duplicate values.

    Apply Data Analysis Filters

    Filter Editor

    Select data analysis filters in the Filter Editor:

    Excel-style Drop-down Filter

    Select data analysis filters in the Excel-style Drop-down Filter:

    In Code

    Use the DataControlBase.FilterString property to apply data analysis filters in code:

    grid.FilterString = "[#TopItems]([Profit], 10)"; // Profit in Top 10 Items
    grid.FilterString = "[#TopPercent]([Profit], 10)"; // Profit in Top 10%
    grid.FilterString = "[#BottomItems]([Profit], 10)"; // Profit in Bottom 10 Items
    grid.FilterString = "[#BottomPercent]([Profit], 10)"; // Profit in Bottom 10%
    grid.FilterString = "[#AboveAverage]([Profit])"; // Profit Above Average
    grid.FilterString = "[#BelowAverage]([Profit])"; // Profit Below Average
    grid.FilterString = "[#Unique]([Profit])"; // Profit is Unique
    grid.FilterString = "[#Duplicate]([Profit])"; // Profit is Duplicate
    

    You can also use the DataControlBase.FilterCriteria property:

    grid.FilterCriteria = new FunctionOperator("#TopItems", new OperandProperty("Profit"), new OperandValue(10)); // Profit in Top 10 Items
    grid.FilterCriteria = new FunctionOperator("#TopPercent", new OperandProperty("Profit"), new OperandValue(10)); // Profit in Top 10%
    grid.FilterCriteria = new FunctionOperator("#BottomItems", new OperandProperty("Profit"), new OperandValue(10)); // Profit in Bottom 10 Items
    grid.FilterCriteria = new FunctionOperator("#BottomPercent", new OperandProperty("Profit"), new OperandValue(10)); // Profit in Bottom 10%
    grid.FilterCriteria = new FunctionOperator("#AboveAverage", new OperandProperty("Profit")); // Profit Above Average
    grid.FilterCriteria = new FunctionOperator("#BelowAverage", new OperandProperty("Profit")); // Profit Below Average
    grid.FilterCriteria = new FunctionOperator("#Unique", new OperandProperty("Profit")); // Profit is Unique
    grid.FilterCriteria = new FunctionOperator("#Duplicate", new OperandProperty("Profit")); // Profit is Duplicate 
    

    Limitations