Eclipse Community Forums Forum Search:

Home » Archived » BIRT » Crosstab taking average of averages
Crosstab taking average of averages Thu, 29 January 2015 17:06
 Shayne PaddockMessages: 11Registered: December 2009 Junior Member
I'm trying to create a survey report which needs to take an average of a group of average scores. The problem is BIRT is calculating the overall average using all of the underlying data instead of taking the average of the 3 already computed averages (groups), is there any way to avoid this?

As an example, a group of questions could be:

Scale 1-100

Teacher - 81.9
Library - 92.9
Playground - 99.3

I want the overall score to be 91.37
(81.9 + 92.9 + 99.3) / 3

But I'm getting a slightly lower number like 91.25 because BIRT isn't taking the average of the 3 averaged numbers (groups) but the average of all the scores in the group.

We are using BIRT 4.3.2 v2

Kindest regards,
Shayne

[Updated on: Thu, 29 January 2015 17:06]

Report message to a moderator

Re: Crosstab taking average of averages [message #1591664 is a reply to message #1591644] Thu, 29 January 2015 17:24
 Michael WilliamsMessages: 1925Registered: July 2009 Senior Member
Could you attach a simple example (using sample database) showing how you have this set up? Thanks.

Michael

Developer Evangelist, Silanis

[Updated on: Thu, 29 January 2015 17:24]

Report message to a moderator

Re: Crosstab taking average of averages [message #1591796 is a reply to message #1591664] Thu, 29 January 2015 18:59
 Shayne PaddockMessages: 11Registered: December 2009 Junior Member
I've taken a screenshot of the output.

What I want to do is generate an average score for Food & Beverage, and then generate an average score for Front Desk. I then want to take those two averages and calculate an overall average for the survey.

What is happening is BIRT is generating the average by taking the sum of the scores of the 15 questions and dividing by 15 instead of just the two averages.

-Shayne
Re: Crosstab taking average of averages [message #1592072 is a reply to message #1591644] Thu, 29 January 2015 22:37
 Michael WilliamsMessages: 1925Registered: July 2009 Senior Member
All you should need to do is select the correct measure grouping to aggregate over in your grand total aggregation expression. Take a look at the attached image.

Michael

Developer Evangelist, Silanis

[Updated on: Thu, 29 January 2015 22:38]

Report message to a moderator

 Previous Topic: RTC Version 4.05 Next Topic: Table Grouping and Sub Report Conflict
Goto Forum:

Current Time: Tue Aug 06 14:28:30 GMT 2024