SUMMARY: Most frequently used words

SUMMARY: Most frequently used words

am 21.01.2008 04:45:18 von buzon

Thank you for you help, specially to Chris that gives me a clue to
solve it.

The solution was:

// store in str_wordlist all different phrases
for($i=0; $i { $str_wordlist .= " ".$arr_phrase[$i]; }

// store in hash_frequencywords the counting values
$hash_frequencywords = array_count_values(explode('
',trim($str_wordlist)));

// descendent sort based on values
arsort($hash_frequencywords);

// store the 20 most frequently words
$arr_20mostusedwords = array_slice(array_keys($hash_frequencywords),
0,20);


IHTH,
,_,
(O,O) J. Alejandro Ceballos Z. buzon@alejandro.ceballos.info
( )
-"-"-------------------------------------------------------- ---------
http://alejandro.ceballos.info movil: 33.1411.6079






Atentamente,

"Felicidad no es hacer lo que uno quiere sino querer lo que uno hace."
-- Jean Paul Sartre

,_,
(O,O) J. Alejandro Ceballos Z. buzon@alejandro.ceballos.info
( )
-"-"-------------------------------------------------------- ---------
http://alejandro.ceballos.info movil: 33.1411.6079

--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php