remove stop words
v0.3.0
從字串中remove stop words 。目前它有法語、西班牙語和英語版本。如果您想包含您的語言,請隨時提交 Pull Request。
composer require rap2hpoutre/remove-stop-words
只需使用字串呼叫remove_stop_words
函數即可。
use function Rap2hpoutre RemoveStopWords remove_stop_words ;
echo remove_stop_words ( ' The quick brown fox jumps over the lazy dog ' );
// quick brown fox jumps lazy dog
您可以提供區域設定作為第二個參數:
use function Rap2hpoutre RemoveStopWords remove_stop_words ;
echo remove_stop_words ( ' Portez ce vieux whisky au juge blond qui fume ' , ' fr ' );
// Portez vieux whisky juge blond fume