Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
jsangerman
Helper II
Helper II

Average across a time period, but sum rows

I have data for percentage of time people spend on a project. It looks like this:

 

Team MemberProjectOctober 2021November 2021December 2021January 2022February 2022March 2022April 2022
AdamProject Alpha40%40%40%40%40%40%40%
AdamProject Beta40%40%40%40%40%40%40%
JohnProject Alpha 25%25%25%   
JohnProject Beta100%100%100%100%100%100%100%
AlanProject Beta100%100%100%100%100%100%100%

 

What I want is to be able to sum the rows, but average across columns as I drill up in dates. So, if I set my rows as Team Member in a table, I should see this:

 

Team MemberOctober 2021November 2021December 2021January 2022February 2022March 2022April 2022
Adam80%80%80%80%80%80%80%
John100%125%125%125%100%100%100%
Alan100%100%100%100%100%100%100%

 

That's easy. However, if I drill up on or summarize the columns to Quarters or Years, if should look like this:

 

Team MemberQ4 2021Q1 2022Q2 2022
Adam80%80%80%
John116.6%108.3%100%
Alan100%100%100%

 

Team Member20212022
Adam80%80%
John116.6%106.25%
Alan100%100%

 

How can I work my formula to do that?

1 ACCEPTED SOLUTION
AlexisOlson
Super User
Super User

Try averaging at the year-month level of granularity.

MonthlySumAvg =
AVERAGEX (
    SUMMARIZE ( dimDate, dimDate[Year], dimDate[Month] ),
    CALCULATE ( SUM ( dataTable[Complete%] ) )
)

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi @jsangerman ,

 

Does the replies above solve your problem? If it has been solved, please mark the correct reply as the standard answer to help the other members find it more quickly.Thanks in advance for your kind cooperation!

 

Hope it helps,


Community Support Team _ Caitlyn

If this post helps then please consider Accept it as the solution to help the other members find it more quickly.

AlexisOlson
Super User
Super User

Try averaging at the year-month level of granularity.

MonthlySumAvg =
AVERAGEX (
    SUMMARIZE ( dimDate, dimDate[Year], dimDate[Month] ),
    CALCULATE ( SUM ( dataTable[Complete%] ) )
)

That seems to do it. Thanks, Alexis.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.