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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
Anonymous
Not applicable

STD

Halo everyone

 

So the STD function does not give me the correct standard deviation at all. I want to calculate the standard deviation of allselected dates, since that is how my average is calculated. I know the std is wrong first because I calculated it in excel and second with a massive workaround I already produced the desired result, but I would love to do it in a simple measure. 

 

The measure I tried is CALCULATE(STDV.S(column), ALLSELECTED(DATES))

 

I then want to add and subtract this from the average to obtain my upper and lower limit respectively as follows

 

image.png

3 REPLIES 3
ChrisMendoza
Resident Rockstar
Resident Rockstar

@Anonymous,

 

Honestly I don't know much about STDEV functions and that's partially the reason why I stopped to read your post. I decided to try and play with some numbers making measures and whatnot and tried to visualize as you have.

 

After reading https://powerpivotpro.com/2013/10/standard-deviation-demystified-in-power-pivot/, near the bottom it states, "Important:  Average and STD DEV Must Have the Same “Granularity”, possibly the reason for your visualization being incorrect is because in the filter context the same grainularity is not maintained.

 

You probably already realized this and that is the reason for your post is to have help with a measure to enforce the granularity.

 

MIght I suggest providing data with the expected values?

 

I look forward to the responses and solution.

 






Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

Proud to be a Super User!



Anonymous
Not applicable

I am not sure what Granularity is, but I will go read your link and maybe I will find out. ( I am fairly new to dax)

 

Allthough the result I posted is correct, it s not dynamic, I can make the average dynamic, but since the std did not work I opted to go for the average over the FY since that is the way it was done in excel. I achieved this through a measure

AVERAGE = CALCULATE(AVERAGE(Column), ALL(Dates), VALUES(Dates[FY])), I then wrote this measure to a column in my table, then another column which calculated the variance and so on and so forth. 

 

Here is the example of what I have and what I wanto achieve, but dynamically so that if I select month, or week, I will see my average, UL, LL for that particular month or week. Well, mine is dynamic in the sense that in changes form fy to fy, but stays static for smaller periods. First Column is my data values, others are all calculated columns

image.png

 

 

 

Anonymous
Not applicable

Ok so I have been using the function STDEV = CALCULATE(STDEV.S(Column), ALLSELECTED(Dates)) and what I have seen now while playing around, that the function is actually very accurate, it is only for the FY18. Now it might be that my data set is already set to 31 august, so it use 365 days as N, but then that would also be the case for my average yet my average function works perfect, I mean allselected means allselected right?

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.