计算给定文本的词频和时间

时间:2019-05-30 09:28:28

标签: python-3.x nlp

我有一个如下数据框。我想查看学期频率和在该时间上花费的总时间

     summary                                                 time spent
1.Many organisations have large amounts of information.          3.5
2.contained in free-text documents.                              1.5
3.Processing these documents often entails.                      4.0
4.the information contained in them.                             3.0
5.Humans read the documents and label metadata.                  6.5
6.some metadata is usually added to the documents.               6.0

我有一个像下面这样的关键字。我想看看下面的关键字在摘要(字数)中出现了多少次,以及花费的时间

1.organisations 
2.information
3.documents
4.label
5.metadata

期望如下输出

    Term        Term Frequency    Total Time Spent
1.organisations         1               3.5
2.information           2               6.5
3.documents             4               18.0
4.label                 1               6.5
5.metadata              2               12.5

0 个答案:

没有答案
相关问题