标签: r text
从单词矢量中查找具有相似子串(至少3个字符)的单词的简单方法是什么?
words <- c("fanboy","fangirl","fanbase","fantastic","fancy", "waddle","goodwill","goodbye","goodies")
例如,我怎么能从这里得到一组五个5个单词,因为它们都包含&#34;粉丝&#34; substring,以及一组最后3个单词,因为它们都包含&#34; good&#34;子?