google spreadsheet - How to use a function as a criteria in COUNTIF -
i have bunch of columns holds scores 3-1
1-4
1-0
2-2
.
i count columns winning, ie. left number higher right one.
i have formula know if column winning : =left(h2; find("-"; h2)-1)-right(h2; find("-"; h2)-1)
what want use formula within countif
, along line :
=countif(a1:a10; "left(current_column; find("-"; current_column)-1)-right(current_column; find("-"; current_column)-1)")
is there way can single formula ?
complex filtering can done filter
, , results can counted counta
. example:
=counta(filter(a:a, left(a:a, find("-", a:a)-1) > right(a:a, find("-", a:a)-1)))
the first argument of filter
range filtered; second formula based on range (or range same row count) returns true or false. rows formula evaluates true returned.
Comments
Post a Comment