我正在尝试从2万条评论中删除单词。单词存储在数据框中,大约有2000多个。注释在其他数据框中,大约20K。
下面是示例:
import pandas as pd
data = pd.Dataframe()
data = ['Hull Damage happened and its insured by maritime hull insurance company','Non Cash Entry and claims are blocked']
stopwords = ['Hull insurance', 'Non Cash Entry']
预期输出:
output = ['Hull Damage happened and its insured by maritime company','and claims are blocked']