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

Popular posts from this blog

Failed to execute goal org.apache.maven.plugins:maven-surefire-plugin:2.12:test (default-test) on project.Error occurred in starting fork -

windows - Debug iNetMgr.exe unhandle exception System.Management.Automation.CmdletInvocationException -

configurationsection - activeMq-5.13.3 setup configurations for wildfly 10.0.0 -