1

I have used the Sentimentr package to do some sentiment analysis because it includes valence shifters. However I cannot find how this lexicon lexicon::hash_sentiment_jockers_rinker was built, how individual words were scored. From what I understand, the lexicon was originally exported by the syuzhet and is a combination of AFFIN, bing, nrc and syuzhet. Could someone help me to understand how individual words in the lexicon were calculated?

Thanks!

Darren Cook
  • 27,837
  • 13
  • 117
  • 217
Gabriella
  • 421
  • 3
  • 11

1 Answers1

1

The NEWS file on github says this for version "2.1.0 - 2.2.3":

The default sentiment sentiment lookup table used within sentimentr is now lexicon::hash_sentiment_jockers_rinker, a combined and augmented version of lexicon::hash_sentiment_jockers (Jockers, 2017) & Rinker's augmented lexicon::hash_sentiment_huliu (Hu & Liu, 2004) sentiment lookup tables.

It doesn't state how it was "combined and augmented", so if that was the essence of your question this might not be much help. In that case I'd suggest studying git history to see where the change was introduced, as the commit message, or source code comments, might explain the details.

Darren Cook
  • 27,837
  • 13
  • 117
  • 217
  • Thats very helpful advice! I will try to do that, if I have any success I will report back. Thank you! – Gabriella Mar 18 '21 at 12:09
  • Hi, sorry I'm pretty new to Git...how can i find the Git history? – Gabriella Mar 18 '21 at 14:07
  • 1
    `git log fname` shows you all the commits that have been done on a file. See https://www.shellhacks.com/git-particular-file-change-history/ which also shows a command to get diffs too. But for serious diff-ing between versions you will want to learn `git diff`, or see if your IDE or editor has helper tools or plugins. – Darren Cook Mar 18 '21 at 14:13