Internal function for calculating count index.
CountIndex(lm)
lm
column vector
count index = largest n where n cells have >= n counts