Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I'm hoping to get some help on how to get the standard deviation of a measure. The intent is to add a flat line of 3x the standard deviation of the complaint rate to this graph:
For reference, the complaint rate calculation is this:
Complaint Rate =
'Complaints Report'[Complaints]
/ SUM ( 'Case Report'[Total Cases] )While "Complaints" is simply:
Complaints =
CALCULATE (
DISTINCTCOUNT ( 'Complaints Report'[Quality Number] ),
'Complaints Report'[Is this a complaint?] = "Yes"
) + 0
My attempt at the standard deviation calculation:
Complaint Rate StdDev =
CALCULATE (
STDEVX.S ( 'Complaints Report', [Complaint Rate] ),
ALLSELECTED ()
)
The above is close to what I'm looking for, but upon double checking the math doesn't seem correct, as it is yielding 0.1368% while calculating it in excel and by hand yields 0.1158%:
I suspect the formula is calculating on a different context than what I want, but I can't figure out how to make it calculate based on the timeframe that is on the graph, which may be in months or quarters and may be more or less than a year in total length.
Any help or advice would be appreciated!
Solved! Go to Solution.
please try
Complaint Rate StdDev =
CALCULATE (
STDEVX.S ( VALUES ( 'Date'[YearMonth] ), [Complaint Rate] ),
ALLSELECTED ()
)
please try
Complaint Rate StdDev =
CALCULATE (
STDEVX.S ( VALUES ( 'Date'[YearMonth] ), [Complaint Rate] ),
ALLSELECTED ()
)
Hi @tamerj1
This seems to have worked! Can you explain the logic behind it? I'm not sure I completely understand.
The X-Aggregators in dax are iterators. The need to iterate the right table at the right granularity.
@PurpleWave22 This looks like a measure aggregation problem. See my blog article about that here: https://community.powerbi.com/t5/Community-Blog/Design-Pattern-Groups-and-Super-Groups/ba-p/138149
The pattern is:
MinScoreMeasure = MINX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
MaxScoreMeasure = MAXX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
AvgScoreMeasure = AVERAGEX ( SUMMARIZE ( Table, Table[Group] , "Measure",[YourMeasure] ), [Measure])
etc.
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 11 | |
| 9 | |
| 9 | |
| 6 | |
| 5 |
| User | Count |
|---|---|
| 27 | |
| 22 | |
| 20 | |
| 17 | |
| 12 |