Understanding CALCULATE in DAX: Percentage of Total

preview_player
Показать описание
This video shows different ways for calculating the percentage of a total in DAX. Using different methods you can manipulate the evaluation context using CALCULATE.

Master Functions and Syntax in M

ABOUT BI Gorilla:
BI Gorilla shares videos and articles on Power BI and Excel to help you improve your skills.

SUPPORT MY CHANNEL

SUBSCRIBE TO MY CHANNEL

LET'S CONNECT:

Thank you for your support!

#DAX #CALCULATE #BIGorilla
Рекомендации по теме
Комментарии
Автор

finallyy man.. i been at work all day trying to find an example of calculating a weighted average... your a lifesaver and earned yourself a new subscriber!! 100%

sd
Автор

This is beyond helpful. Was totally struggling on the Dax syntax for this. Super greatful. Especially for the part where the column will change for a new or 2nd pivot.

jahmed
Автор

I’ve looked everywhere on the internet to find a solid way to calculate the percentage of total row, and this is exactly what I was looking for.

Thank you for the well explained video!

kitchenerpeckford
Автор

Thank you so very much! I spent all day yesterday trying to get this exact work done. I'm grateful

sublimefan
Автор

great explanation, 4 days searching for this solution, Many Thanks ❤❤👌👌

moatazmohamed
Автор

Thank you so much for sharing. Excellent explanation of how this is done step by step.

nohairybear
Автор

This was exactly what I was searching for. Thank you!

stanislavvincent
Автор

Thank you. Exactly what I have been looking for. To calculate the % of subtotals.

jyotidatta
Автор

Brilliant video, thank you so much. By far the best explaination of this I've seen. Thank you for taking the time to make and share.

MultiCreasey
Автор

This is fantastic, gold star for me when I use this in my report. Many thanks

terrylee
Автор

This is a great tutorial to create total percentages in DAX. I have one question I'd would like your help. Let's say I am creating a matrix visual about some population distribution across states. I also break down the states' distribution by demographics such as age group, gender, race group (in the matrix, state is the row field, and gender, or age group, or race are the columns). To show the row percentages for different categories of age group, gender, or race group, I would like to create a DAX measure; the row total disregarding gender should be:
VAR population_rowtotal=
CALCULATE(
[# population],

)
)
I can calculate the row percentages as DIVIDE([# population], [population_rowtotal]).
This DAX measure is for row percentages for gender only. I can also create DAX measures for row percentages of race, or age group.
But I would like to use a parameter including gender, race, age groups, as the column in the matrix. So the matrix will be dynamic based on the column field I select. That means the Dax measure of row total / percentage should also be dynamic based on the selected column field. How can I achieve this in the DAX measure statement:
or [racegroup] or [agegroup]).
Thanks.

lijunchen
Автор

Hi, a question, you didnt show how the [ sales ] measure was created, do you mind explaining?

anthonyanyoti
Автор

Hi there wonderful video thank you so much! Quick question, what application do you use to Box (red) around a certain area while demo'ing something? I have Zoomit, which is helpful with Zooming but not very easy to get to a box.

ShadyMickhail
Автор

Hi Gorilla,

Great thanks for this Clips. It is very informative. I had one query, whether the figures will get change as per filter selection. Thanks in Advance

shandar
Автор

Hi Rick, this is really good and helpful. I had a question. What if I want my row total to be treated as 100% and then each cell of that row reflects the % contribution leading to the row total.
Is this possible. How will the DAX work in this scenario.
Any help or idea is appreciated.
Thanks a lot.
Regards.

dhritijitsengupta
Автор

Hi, well I'm an 'All ' person, simply because I can use it in Bi or PP. My question is this, if removing all filter to create the denominator, i've used
CALCULATE( [Total sales], All(CALENDAR ), ALL(Sales Table) ), as I don't always know what I'm going to be dropping in to the visual, usually matrix, I can't help feeling there should be a better approach, I've tried using summarize and crossjoin, any suggestions on removing filters from multiple tables

williamarthur
Автор

Hi Sir, facing an issue need your help for the mentioned below
I have a Project with 3 Location columns and 1 value columns (WTG = 100% sum of all location activities) in power Bi. I want to see percentage in the Card visual chart and it should be link with locations. means when I select location or its sub location so it show me cumulative percentage of that selected location only calculating it as 100%.

Construction = 100%
Pipeline = 45%
Wellheads = 30%
Processing Plant = 25%

I want like this if i select construction the Card visual show me percentage from 100% and when i select its sub-phases e.g. pipeline then it should not show me 45%; it should show me 100% so that i can change the date and calculate the variance in one visual.

constructionprojects
Автор

What is the difference between "Return variable name" and "Return Result"? Thank you!

susanknoll
Автор

great video..can we follow similar process when calculating margin% yearly

vamshidharreddy
Автор

I’m trying to use this video to calculate the percentage of subtotals - so to use the data from your example 4 is 13% of 31 (the total for regular).

claires