Research Article

Context-Based Emotion Predictor: A Decision- Making Framework for Mobile Data

Algorithm 1

Proposed ACED algorithm for sentiment detection.
Input: text data for emotion prediction
Output: emotional and sentiment score1
(1)FOR T ← Token//at the end of FOR loop clean text is returned
(2)IF T is in StopwordList THEN
(3)  Remove Stopword
(4)ELSE
(5)  IF T is in InfectedForm THEN
(6)   Lemmatize the Token
(7)   Assign Part of Speech Tag
(8)  ELSE
(9)   Assign Part of Speech Tag
(10)  END
(11)END
(12)END
(13)FOR T ← Token
(14)IF T is in SentiWordNet THEN
(15)  assign sentiment score
(16)ELSE
(17)  IF T is in NegationList THEN
(18)   reverse sentiment score
(19)  ELSE
(20)   assign zero to sentiment score
(21)  END
(22)END
(23)END