added methods to count the occurence of a special color