Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi experts,
I would like to calculate Variance of some values with this dax code:
Gesamtauslastung:=
var x= SUMX(CheckoutUtilization;CALCULATE(((CheckoutUtilization[NumberOfParallelCheckouts] / CheckoutUtilization[MaxNumberOfCheckouts])* CheckoutUtilization[MinutesOfParallelCheckoutUsage]) / CheckoutUtilization[DailyTotalMinutesOfCheckoutUsage];CheckoutUtilization[Date_SID];CheckoutUtilization[_NumberOfParallelCheckouts]))
return CALCULATE(VARX.P(CheckoutUtilization;x);ALLSELECTED('date'))
But what I see as result is minus values, as I understood Variance is allways +. Why do I get such a result?
1- I would like to calculate variance of these values.
As you can see reault of variance is minus
Solved! Go to Solution.
[Auslastung] =
SUMX(
CheckoutUtilization,
CheckoutUtilization[NumberOfParallelCheckouts]
/ CheckoutUtilization[MaxNumberOfCheckouts]
* CheckoutUtilization[MinutesOfParallelCheckoutUsage]
/ CheckoutUtilization[DailyTotalMinutesOfCheckoutUsage]
)
Gesamtauslastung :=
CALCULATE(
VARX.P(
CheckoutUtilization,
[Auslastung]
),
ALLSELECTED( 'date' )
)
You need something like the above...
[Auslastung] =
SUMX(
CheckoutUtilization,
CheckoutUtilization[NumberOfParallelCheckouts]
/ CheckoutUtilization[MaxNumberOfCheckouts]
* CheckoutUtilization[MinutesOfParallelCheckoutUsage]
/ CheckoutUtilization[DailyTotalMinutesOfCheckoutUsage]
)
Gesamtauslastung :=
CALCULATE(
VARX.P(
CheckoutUtilization,
[Auslastung]
),
ALLSELECTED( 'date' )
)
You need something like the above...
@Fariba1984 - VARX.P uses the formula:
∑(x - x̃)2/n
So if n is negative, I suppose you will get negative results.
It is population size and population size can not be negative
@Fariba1984 - Well, it wouldn't be the first time I found weirdness with DAX functions. https://community.powerbi.com/t5/Quick-Measures-Gallery/To-bleep-with-MOD/m-p/1081806#M509
You could check the Issues forum here:
https://community.powerbi.com/t5/Issues/idb-p/Issues
And if it is not there, then you could post it.
If you have Pro account you could try to open a support ticket. If you have a Pro account it is free. Go to https://support.powerbi.com. Scroll down and click "CREATE SUPPORT TICKET".
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
43 | |
23 | |
21 | |
15 | |
15 |
User | Count |
---|---|
45 | |
31 | |
30 | |
18 | |
17 |