getCountsArray method