+ Reply to Thread
Results 1 to 9 of 9

How to calc stdev but to exclude 0's. Prefer no array cntrl + Shift + enter calcs

Hybrid View

  1. #1
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,712

    How to calc stdev but to exclude 0's. Prefer no array cntrl + Shift + enter calcs

    I have a list of numbers and i want to calculate avg and stdev but i do not want "zeros" or "blanks" to enter into the calculations. I have a formula for avg but i need one for stdev.
    Last edited by welchs101; 12-12-2008 at 07:20 PM.

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    If you have a formula that works for AVERAGE, just change AVERAGE to STDEV.
    Entia non sunt multiplicanda sine necessitate

  3. #3
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,712

    cant just replace STDEV and AVG.....wont work

    formula for avg:
    SUM(A1:A5)/COUNTIF(A1:A5,">0")


    Cant just replace avg with stdev

  4. #4
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    =stdev(if(a1:a5>0, a1:a5))

    That is an array formula, though.

  5. #5
    Forum Contributor
    Join Date
    12-01-2007
    Location
    USA-North Carolina
    MS-Off Ver
    MS Office 2016
    Posts
    2,712

    hi

    Yeah, its hard to find a formula with out using the array calc.

  6. #6
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689
    You could do it with a helper column: =if(a1>0, (a1-avg)^2, ""), where avg is the value you computed with your other formula.

    Then St Dev =sqrt(sum(B1:B5) / (count(b1:b5) - 1) )

    Why the aversion to array formulas?
    Last edited by shg; 12-12-2008 at 06:59 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1