=SUMPRODUCT(($B$3:$B$200=D7)*(SUBTOTAL(103,OFFSET($B$3,ROW($B$3:$B$200)-MIN(ROW($B$3:$B$200)),0))))
will countif visible cells. If you then use the data in the chart (currently it is using externally held data which I cannot access, then turn the 0 into a #N/A error.
=IFERROR(1/(1/SUMPRODUCT(($B$3:$B$200=D7)*(SUBTOTAL(103,OFFSET($B$3,ROW($B$3:$B$200)-MIN(ROW($B$3:$B$200)),0))))),NA())
Excel will ignore, and not plot, the NA values.
Then use this:
=SUBTOTAL(3,$B$3:$B$200)
to return the total numbe rof visible rows.
Bookmarks