NClassifier.Summarizer.SimpleSummarizer.GetMostFrequentWords C# (CSharp) Méthode

GetMostFrequentWords() protected méthode

protected GetMostFrequentWords ( int count, Hashtable wordFrequencies ) : ArrayList
count int
wordFrequencies System.Collections.Hashtable
Résultat System.Collections.ArrayList
        protected ArrayList GetMostFrequentWords(int count, Hashtable wordFrequencies)
        {
            ArrayList result = new ArrayList();
            int freq = 0;
            foreach (DictionaryEntry entry in wordFrequencies)
                if ((int)entry.Value > freq)
                    freq = (int)entry.Value;
            while (result.Count < count && freq > 0)
            {
                string[] words = FindWordsWithFrequency(wordFrequencies, freq);
                foreach (string word in words)
                    result.Add(word);
                freq--;
            }
            return result;
        }