Articles in this section
Category / Section

How to group data by age range and display in a chart

Published:

Grouping data by age range lets you compare the values of different age groups and identify any trends easily. This is particularly useful when dealing with large datasets that need to be analyzed or presented in a meaningful way. For example, here we have grouped the data by patients' age range.

Steps to group data by age range
  1. Drag and drop the Stacked Column Chart to the designer canvas. You can also choose any other charts and tables.
  2. Navigate to its Assign Data section and configure the Value(s) and Row sections with Patient_Id and Gender columns respectively.

    Configure Value(s) and Row section in Assign Data panelConfigure Value(s) and Row section in Assign Data panel
  3. To create age ranges, create an expression column named "Age Group" with the following expression. This will group the ages based on the criteria added to the expression.
IF([Age]>0 AND [Age]<10,'0-10',IF([Age]>10 AND [Age]<=30,'10-30',IF([Age]>30 AND [Age]<40,'30-40',IF([Age]>= 40 AND [Age]<50 ,'40-50',IF([Age]>=50,'Above 50','0')))))
       4. Drag and Drop this expression column to the Column(s) section as shown:

    Configure Column(s) section in Assign Data panelConfigure Column(s) section in Assign Data panel

       5. Now, data will be grouped by age range as shown:
Stacked Column Chart grouped by age rangeStacked Column Chart with data grouped by age range


Was this article useful?
Like
Dislike
Help us improve this page
Please provide feedback or comments
SG
Written by Sivabalan Ganesan
Updated
Comments (0)
Please  to leave a comment
Access denied
Access denied