if(type === 'most') refCount = Math.max.apply(null, allValues);
            else  refCount = Math.min.apply(null, allValues);