Questions tagged [sentiment-analysis]

Sentiment analysis refers to categorizing some given data as to what sentiment(s) it expresses. Usually, it refers to extracting sentiment from text, e.g. tweets or blog posts.

2020 questions
19
votes
3 answers

Emoticons in Twitter Sentiment Analysis in r

How do I handle/get rid of emoticons so that I can sort tweets for sentiment analysis? Getting: Error in sort.list(y) : invalid input Thanks and this is how the emoticons come out looking from twitter and into…
Rhodo
  • 1,234
  • 4
  • 19
  • 35
16
votes
3 answers

Good dataset for sentiment analysis?

I am working on sentiment analysis and I am using dataset given in this link: http://www.cs.jhu.edu/~mdredze/datasets/sentiment/index2.html and I have divided my dataset into 50:50 ratio. 50% are used as test samples and 50% are used as train…
user3512562
  • 233
  • 2
  • 3
  • 7
16
votes
4 answers

calculate accuracy and precision of confusion matrix

Is there any tool / R package available to calculate accuracy and precision of a confusion matrix? The formula and data structure are here.
Ajay Singh
  • 289
  • 1
  • 3
  • 10
15
votes
1 answer

'Can't return head of null or leaf Tree' with CoreNLP on Android

I want to use CoreNLP in my Android project. But when I create a CoreNLP instance like this: import java.util.Properties; import edu.stanford.nlp.ling.CoreAnnotations; import edu.stanford.nlp.neural.rnn.RNNCoreAnnotations; import…
user2212461
  • 3,105
  • 8
  • 49
  • 87
15
votes
3 answers

How to train the Stanford NLP Sentiment Analysis tool

Hell everyone! I'm using the Stanford Core NLP package and my goal is to perform sentiment analysis on a live-stream of tweets. Using the sentiment analysis tool as is returns a very poor analysis of text's 'attitude' .. many positives are labeled…
Jordan H
  • 181
  • 1
  • 2
  • 11
15
votes
1 answer

List of Natural Language Processing Tools in Regards to Sentiment Analysis - Which one do you recommend

first up sorry for my not so perfect English... I am from Germany ;) So, for a research project of mine (Bachelor thesis) I need to analyze the sentiment of tweets about certain companies and brands. For this purpose I will need to script my own…
Chriswede
  • 935
  • 2
  • 12
  • 31
15
votes
4 answers

Sentiment Analysis of Entity (Entity-level Sentiment Analysis)

I've been working on document level sentiment analysis since past 1 year. Document level sentiment analysis provides the sentiment of the complete document. For example - The text "Nokia is good but vodafone sucks big time" would have a negative…
Jasneet
  • 302
  • 4
  • 14
15
votes
3 answers

Logical fallacy detection and/or identification with natural-language-processing

Is there a package or methodology in existence for the detection of flawed logical arguments in text? I was hoping for something that would work for text that is not written in an academic setting (such as a logic class). It might be a stretch but…
Usagi
  • 2,896
  • 2
  • 28
  • 38
13
votes
3 answers

Perl or Java Sentiment Analysis

I was wondering if anybody knew of any good Perl modules and/or Java classes for sentiment analysis. I have read about LingPipe, but the program would eventually need to be used for commercial use so something open-source would be better. I also…
user387049
  • 6,647
  • 8
  • 53
  • 55
13
votes
1 answer

Classification using movie review corpus in NLTK/Python

I'm looking to do some classification in the vein of NLTK Chapter 6. The book seems to skip a step in creating the categories, and I'm not sure what I'm doing wrong. I have my script here with the response following. My issues primarily stem from…
user3128184
  • 213
  • 1
  • 2
  • 9
12
votes
2 answers

German Stemming for Sentiment Analysis in Python NLTK

I've recently begun working on a sentiment analysis project on German texts and I'm planning on using a stemmer to improve the results. NLTK comes with a German Snowball Stemmer and I've already tried to use it, but I'm unsure about the results.…
Florian
  • 155
  • 1
  • 9
12
votes
3 answers

Python - Sentiment Analysis using Pointwise Mutual Information

from __future__ import division import urllib import json from math import log def hits(word1,word2=""): query = "http://ajax.googleapis.com/ajax/services/search/web?v=1.0&q=%s" if word2 == "": results = urllib.urlopen(query %…
keshr3106
  • 413
  • 3
  • 10
  • 21
11
votes
2 answers

Is it possible to edit NLTK's vader sentiment lexicon?

I would like to add words to the vader_lexicon.txt to specify polarity scores to a word. What is the right way to do so? I saw this file in AppData\Roaming\nltk_data\sentiment\vader_lexicon. The file consists of the word, its polarity, intensity,…
noobalert
  • 855
  • 3
  • 10
  • 24
10
votes
3 answers

Token indices sequence length is longer than the specified maximum sequence length for this model (651 > 512) with Hugging face sentiment classifier

I'm trying to get the sentiments for comments with the help of hugging face sentiment analysis pretrained model. It's returning error like Token indices sequence length is longer than the specified maximum sequence length for this model (651 > 512)…
10
votes
2 answers

how are sentiment analysis computed in blob

I use the following to compute the sentiment of 200 short sentences. I did not use a training data set: for sentence in textblob.sentences: print(sentence.sentiment) The analysis returns two values: polarity and subjectivity. From what I read…
MarieJ
  • 619
  • 7
  • 14