R 中的“情感”包已从 Cran 存储库中删除。还有哪些可以进行情绪分析的软件包?
例如,我如何使用其他包重写它?
library(sentiment)
# CLASSIFY EMOTIONS
classify_emotion(some_txt,algorithm="bayes",verbose=TRUE)
# classify polarity
class_pol = classify_polarity(some_txt, algorithm="bayes")
这里的文档定义为:
# DEFINE text
some_txt<- c("I am very happy at stack overflow , excited, and optimistic.",
"I am very scared from OP question, annoyed, and irritated.")