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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
sandman153
Regular Visitor

Avg Subtotal

Hi 

 

I have a visual with a matrix and am trying to get the subtotals as an average rather than a sum. How would I go about doing this?

 

Is this feasible?


Thanks

Sarath

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi, you can use "average per category" quick measure, to learn about "quick measures" check here.

 

In the example, with the quick measure i get "average of sales monthly" instead of the "sum of sales":

 

The code of the "quick measure" is:

 

SALES average per DATE =
AVERAGEX(
    KEEPFILTERS(VALUES('Table'[DATE])),
    CALCULATE(SUM('Table'[SALES]))
)



sales.png

 

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Hi, you can use "average per category" quick measure, to learn about "quick measures" check here.

 

In the example, with the quick measure i get "average of sales monthly" instead of the "sum of sales":

 

The code of the "quick measure" is:

 

SALES average per DATE =
AVERAGEX(
    KEEPFILTERS(VALUES('Table'[DATE])),
    CALCULATE(SUM('Table'[SALES]))
)



sales.png

 

Thank you Maguilar. This helped me achieve Average value in column subtotals. 

Thanks Maguilar

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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