【问题标题】:How to find intensity from TextBlob sentiment analysis如何从 TextBlob 情绪分析中找到强度
【发布时间】:2020-06-17 15:52:41
【问题描述】:

我在 Python 3.7 上使用 TextBlob 包中的情绪分析工具。我熟悉它和understand that it works on a basis of 3 values:极性、主观性和强度。极性和主观性是TextBlob('string').sentiment 的标准输出,但遗憾的是TextBlob('string').intensity 没有成功。这有什么线索吗?

【问题讨论】:

    标签: python python-3.x sentiment-analysis textblob


    【解决方案1】:

    我认为 textblob 库中没有计算强度的选项。

    1) 情感函数请参考源码第439行:https://github.com/sloria/TextBlob/blob/dev/textblob/blob.py

    它提供了一个计算极性和主观性的选项,但没有强度参数。

    2)如果我们谈论单独的功能(您提到的),它在源代码中也没有。

    3) 以下链接提供并显示包含强度和置信度,但源代码缺少该功能。

    https://github.com/sloria/TextBlob/blob/eb08c120d364e908646731d60b4e4c6c1712ff63/textblob/en/en-sentiment.xml

    【讨论】:

    • 感谢您的帮助。我想我将不得不稍微更改我的代码!
    猜你喜欢
    • 1970-01-01
    • 2016-06-04
    • 2017-07-15
    • 2019-08-17
    • 1970-01-01
    • 2018-03-19
    • 1970-01-01
    • 2013-02-02
    • 2020-08-14
    相关资源
    最近更新 更多