Number Average function gives incorrect answer

I have a simple table of numbers and calculated the average. The result is incorrect. The I do a SUM and then divide by the number of entries, I get the correct result. All cells have data format of "Number". I did a screenshot of the formula being used at the end of the table.

Posted on Aug 27, 2021 10:51 AM

Reply
Question marked as Top-ranking reply

Posted on Aug 27, 2021 5:42 PM

I am of a different opinion. If a comma by itself is the same as ,0 then it is very consistent, at least with the examples we have mentioned so far and it matches up with what is written in the descriptions of some functions. In some functions, a parameter that is omitted (i.e., just a comma, no value) is the same as setting it to zero. Until today it never dawned on me to equate "omitted" = 0 but now it seems obvious. I also never realized it was used in other functions, like you found out with AVERAGE. Doesn't seem to be universal, though.


SUM(B2:B15,) is the same as SUM(B2:B15,0). Adding a zero does not affect a sum so both are the same as SUM(B2:B15).


AVERAGE(B2:B15,) is the same as AVERAGE(B2:B15,0) which is not the same as AVERAGE(B2:B15). Averaging in an extra zero affects an average.


The example of DURATION is 0 weeks, 0 days, 0 hrs, 1 minute, 0 seconds. That last comma in DURATION(0,0,0,1,) is for the seconds, which does not change the duration because it is 0 seconds.


If you feel it is a bug or a mistake or inconsistent, please use the menu item Numbers/Provide Numbers Feedback to inform the iWork team. That is the official channel for reporting problems, bugs, suggestions, etc.

5 replies
Question marked as Top-ranking reply

Aug 27, 2021 5:42 PM in response to Kazaar-Arpeggio

I am of a different opinion. If a comma by itself is the same as ,0 then it is very consistent, at least with the examples we have mentioned so far and it matches up with what is written in the descriptions of some functions. In some functions, a parameter that is omitted (i.e., just a comma, no value) is the same as setting it to zero. Until today it never dawned on me to equate "omitted" = 0 but now it seems obvious. I also never realized it was used in other functions, like you found out with AVERAGE. Doesn't seem to be universal, though.


SUM(B2:B15,) is the same as SUM(B2:B15,0). Adding a zero does not affect a sum so both are the same as SUM(B2:B15).


AVERAGE(B2:B15,) is the same as AVERAGE(B2:B15,0) which is not the same as AVERAGE(B2:B15). Averaging in an extra zero affects an average.


The example of DURATION is 0 weeks, 0 days, 0 hrs, 1 minute, 0 seconds. That last comma in DURATION(0,0,0,1,) is for the seconds, which does not change the duration because it is 0 seconds.


If you feel it is a bug or a mistake or inconsistent, please use the menu item Numbers/Provide Numbers Feedback to inform the iWork team. That is the official channel for reporting problems, bugs, suggestions, etc.

Aug 27, 2021 11:51 AM in response to Kazaar-Arpeggio

I see in your AVERAGE formula a comma that should not be there. That is the problem. Remove it. It is creating a 15th value that happens to be zero.


It is a little strange. When I add that extra comma to AVERAGE(B2:B15) it becomes AVERAGE(B2:B15, value...) with no change to the answer. If I then delete the oval that has "value..." in it, but leave the comma, I get the result you get. There are other functions that will let you put commas with no parameters/values and it treats them as zeros. That appears to be what is going on here as well vs it being a bug.


This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

Number Average function gives incorrect answer

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.