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

View all the Fabric Data Days sessions on demand. View schedule

Reply
krisplikj
Frequent Visitor

Standard Deviation from varying starting points

Hello Power BI enthusiasts,

 

Hoping someone can help here.  I have a data set that I need to calculate the stanard deviation for each row.  The catch is, I need the calculate it from the first "non zero" cell moving from left to right.  (or I could reorder the data points from right to left, if easier).  So, the first row would start on column 35, row 2 would start at column 36, row 3 at column 32, and so on.  It makes no difference if the best solution is simply by adding columns or DAX.

 

Many thanks in advance for any ideas and / or support.  Thanks!

 

krisplikj_0-1681670849008.png

 

1 ACCEPTED SOLUTION

Hi Ibendlin, thanks for the advice,  I'm going to close this thread and start a new one with the sample data in the correct format.  Best Regards.

 

View solution in original post

3 REPLIES 3
lbendlin
Super User
Super User

Please provide sample data that covers your issue or question completely, in a usable format (not as a screenshot).
https://community.powerbi.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-Forum/ba-...
Please show the expected outcome based on the sample data you provided.

https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523

Hi Ibendlin, thanks for the advice,  I'm going to close this thread and start a new one with the sample data in the correct format.  Best Regards.

 

krisplikj
Frequent Visitor

Hello again,

 

When I've posted in the past, I would normally get a solution relatively quickly.  Since this has not happened yet, I'm guessing with the way I presented the question below, a solution is not possible.  That said, I am rephrasing the question in a way that I believe there is a solution based off other questions I've seen solved.

 

So in the previous screenshot, I had converted the dates into number of months from the current month and pivoted the data.  Here I have an unpivoted table where in another query, I found the min month of "non zeroes" by region and then merged queries with this one.  The "calendar year / month" column has 36 Months of data points while the "St Dev Lookup. Min Month" references the first "non-zero" month that occurred.  Can anyone tell me how to do a standard deviation on the "Test" Column where it only starts counting at the "St Dev Lookup.Min Month" occurrence?  And by the way, I do want to include any zeroes that occurred after the Min Month.  Kudos to anyone that can help and thanks again in advance!

 

krisplikj_1-1681772816741.png

 

 

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.