ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Finding non contiguous positive values (https://www.excelbanter.com/excel-worksheet-functions/137023-finding-non-contiguous-positive-values.html)

Nick Krill

Finding non contiguous positive values
 
I'm using the following to sum the last 10 non blank cells in column A (which
has over 500 rows with empty cells randomly distributed):

=Sum(A100:Index(A1:A100,Large(Row(A1:A100)*(A1:A10 0<""),10)))

Now I need to find how many of those 10 cells have positive numbers so that
I can then divide by 10 and arrive at a percentage of positive cells. Any
suggestions??



Domenic

Finding non contiguous positive values
 
Try...

=COUNTIF(INDEX(A1:A100,LARGE(IF(A1:A100<"",ROW(A1 :A100)-ROW(A1)+1),10)):
A100,"0")

....confirmed with CONTROL+SHIFT+ENTER.

Hope this helps!

In article ,
Nick Krill wrote:

I'm using the following to sum the last 10 non blank cells in column A (which
has over 500 rows with empty cells randomly distributed):

=Sum(A100:Index(A1:A100,Large(Row(A1:A100)*(A1:A10 0<""),10)))

Now I need to find how many of those 10 cells have positive numbers so that
I can then divide by 10 and arrive at a percentage of positive cells. Any
suggestions??



All times are GMT +1. The time now is 05:46 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com