Average of non-zeros

Brass Contributor

Hello!  I am trying to get an average of non-zero values.  So for the row one, I need it to be 0, but for row 2, I need it to be we have one value, and we divide by one value.  So I need:

Sum(all the values) / (number of cells that have a value greater than 0).

 

Thanks in advance!

 

nattiej101_0-1660331560250.png

 

2 Replies

@nattiej101 

=AVERAGEIF(A2:D2,">0",A2:D2)

You can try AVERAGEIF which returns the expected result in my sheet.

Averageif.JPG 

@nattiej101 

=AVERAGEIF(A4:F4,">0")