0

我在熊猫中有一个专栏,如下所示

0    ['business', 'ceremony', 'festival', 'group']

1    ['mountain', 'outdoors', 'travel', 'tree', 'forest']

2    ['people', 'city', 'politics', 'architecture']

3    ['people', 'politics', 'protest', 'travel']

4    ['automobile', 'business', 'police', 'transporation']

我想找到相似的词并减少到几个词来表示列,即减少相似的词并使用最常见的词。

输入:

[automobile, business, police, transportation, vehicle]

输出:

[Vehicle, business, police]

提前致谢

4

0 回答 0