IEEE Computational Intelligence Magazine - November 2019 - 84

experiment also served to justify the use
of the full vocabulary size for the two
different datasets. It is not surprising that
the highest value for the vocabulary size
produces the best results for both tasks,
given the small size of tweets. Moreover,
some hashtags, one of the distinctive fea-

tures of tweets, may occur rarely but
they are highly informative keywords.
Similarly, for KLINGER, Tables 3
and 4 indicate the accuracy and F-measure
we obtained for the baseline method in
both tasks. In particular, for the first task,
we used the figurative (balanced) and

TABLE 1 Setting the threshold for the optimal feature size for the figurative
language dataset of SEMEVAL and baseline accuracy and F-measure comparison
using unigrams.
BOW - 5,000
(> 5 OCCURRENCES)

BOW - 7,000
(> 3 OCCURRENCES)

BOW - 15,000
(> 2 OCCURRENCES)

BOW - 55,000
(> 1 OCCURRENCE)

ACC.

0.85

0.86

0.87

0.90

F.

0.86

0.89

0.90

0.92

TABLE 2 Setting the threshold for the optimal feature size for the irony/sarcasm
dataset of SEMEVAL and baseline accuracy and F-measure comparison using
unigrams.
BOW - 1,000
(> 5 OCCURRENCES)

BOW - 2,000
(> 3 OCCURRENCES)

BOW - 3,000
(> 2 OCCURRENCES)

BOW - 15,000
(> 1 OCCURRENCE)

ACC.

0.84

0.86

0.82

0.88

F.

0.88

0.89

0.85

0.93

TABLE 3 Setting the threshold for the optimal feature size for the figurative
language dataset of KLINGER and baseline accuracy and F-measure comparison
using unigrams.
BOW - 5,000
BOW - 7,000
BOW - 15,000
BOW - 70,000
(> 11 OCCURRENCES) (> 8 OCCURRENCES) (> 3 OCCURRENCES) (> 1 OCCURRENCE)
ACC. 0.80

0.85

0.87

0.89

F.

0.82

0.86

0.88

0.79

TABLE 4 Setting the threshold for the optimal feature size for the irony/sarcasm
dataset of KLINGER and baseline accuracy and F-measure comparison using
unigrams.
BOW - 5,000
(> 9 OCCURRENCES)

BOW - 7,000
(> 6 OCCURRENCES)

BOW - 15,000
(> 3 OCCURRENCES)

BOW - 65,000
(> 1 OCCURRENCE)

ACC.

0.75

0.76

0.77

0.78

F.

0.76

0.77

0.78

0.79

TABLE 5 Accuracy and F-measure for the figurative language detection problem
across the different features models on SEMEVAL.

84

FEATURES

ACC. TF.IDF

ACC. BOW

F. TF.IDF

F. BOW

UNIGRAMS

0.72

0.90

0.74

0.92

BABELNET SYNSETS

0.73

0.86

0.74

0.88

SEMANTIC FRAMES

0.56

0.68

0.59

0.72

BNS+SF

0.72

0.86

0.75

0.88

UNIGRAMS+BNS

0.77

0.94

0.79

0.95

UNIGRAMS+SF

0.76

0.92

0.78

0.93

UNIGRAMS+BNS+SF

0.74

0.92

0.75

0.94

IEEE COMPUTATIONAL INTELLIGENCE MAGAZINE | NOVEMBER 2019

the regular dataset whereas for the second task we used the irony and the sarcasm datasets. To note that irony and
sarcasm tweets size of KLINGER are
much higher than those of SEMEVAL;
this explains why we had higher threshold values in Table 4.
For each dataset, two Naive Bayes
classifiers were trained using unigram
features and TF-IDF features. In the second case, each word was represented
using its TF-IDF value instead of frequency. Tables 5 and 6 show the accuracy and F-measure obtained for each of
the seven features models in the figurative language detection task for
SEMEVAL whereas Tables 7 and 8
show results on KLINGER. The results
have been calculated using 10-fold
cross-validation and averaged over 10
runs (also for the baselines/unigrams).
The accuracy has been calculated as
accuracy = (TP + TN )/(TP + TN + FP +
FN ) and the F-measure as: F-measure =
(2 ) TP )/(2 ) TP + FP + FN ), where TP,
TN, FP and FN correspond, respectively,
to true positives, true negatives, false
positives and false negatives. Table 9 and
Table 10 illustrate the process of computing TP, TN, FP and FN with the help
of the confusion matrices for the two
tasks with values for the baselines on
SEMEVAL. It should be noticed that for
the task 1 and 2, an under-sampling of
the majority class (sarcastic and nonfigurative tweets) was performed. Sarcastic tweets were reduced from 2,081 to
1,350 whereas non-figurative tweets
were reduced from 8,959 and to 3,400.
We thus obtained balanced datasets for
the two classification tasks.
For task 1, using semantic features
improves the classification with respect to
unigrams (which represents our baseline)
for all the combinations including both
unigrams and the semantic features. The
combinations that resulted in the lowest
accuracy (lower than the baseline) were
those employing semantic frames without
unigrams (e.g., BabelNet synsets, semantic frames, BabelNet synsets + semantic
frames). This suggests a connection
between the style of text when adopting
figurative language expression to denote
either irony or sarcasm. Also, the adoption



IEEE Computational Intelligence Magazine - November 2019

Table of Contents for the Digital Edition of IEEE Computational Intelligence Magazine - November 2019

Contents
IEEE Computational Intelligence Magazine - November 2019 - Cover1
IEEE Computational Intelligence Magazine - November 2019 - Cover2
IEEE Computational Intelligence Magazine - November 2019 - Contents
IEEE Computational Intelligence Magazine - November 2019 - 2
IEEE Computational Intelligence Magazine - November 2019 - 3
IEEE Computational Intelligence Magazine - November 2019 - 4
IEEE Computational Intelligence Magazine - November 2019 - 5
IEEE Computational Intelligence Magazine - November 2019 - 6
IEEE Computational Intelligence Magazine - November 2019 - 7
IEEE Computational Intelligence Magazine - November 2019 - 8
IEEE Computational Intelligence Magazine - November 2019 - 9
IEEE Computational Intelligence Magazine - November 2019 - 10
IEEE Computational Intelligence Magazine - November 2019 - 11
IEEE Computational Intelligence Magazine - November 2019 - 12
IEEE Computational Intelligence Magazine - November 2019 - 13
IEEE Computational Intelligence Magazine - November 2019 - 14
IEEE Computational Intelligence Magazine - November 2019 - 15
IEEE Computational Intelligence Magazine - November 2019 - 16
IEEE Computational Intelligence Magazine - November 2019 - 17
IEEE Computational Intelligence Magazine - November 2019 - 18
IEEE Computational Intelligence Magazine - November 2019 - 19
IEEE Computational Intelligence Magazine - November 2019 - 20
IEEE Computational Intelligence Magazine - November 2019 - 21
IEEE Computational Intelligence Magazine - November 2019 - 22
IEEE Computational Intelligence Magazine - November 2019 - 23
IEEE Computational Intelligence Magazine - November 2019 - 24
IEEE Computational Intelligence Magazine - November 2019 - 25
IEEE Computational Intelligence Magazine - November 2019 - 26
IEEE Computational Intelligence Magazine - November 2019 - 27
IEEE Computational Intelligence Magazine - November 2019 - 28
IEEE Computational Intelligence Magazine - November 2019 - 29
IEEE Computational Intelligence Magazine - November 2019 - 30
IEEE Computational Intelligence Magazine - November 2019 - 31
IEEE Computational Intelligence Magazine - November 2019 - 32
IEEE Computational Intelligence Magazine - November 2019 - 33
IEEE Computational Intelligence Magazine - November 2019 - 34
IEEE Computational Intelligence Magazine - November 2019 - 35
IEEE Computational Intelligence Magazine - November 2019 - 36
IEEE Computational Intelligence Magazine - November 2019 - 37
IEEE Computational Intelligence Magazine - November 2019 - 38
IEEE Computational Intelligence Magazine - November 2019 - 39
IEEE Computational Intelligence Magazine - November 2019 - 40
IEEE Computational Intelligence Magazine - November 2019 - 41
IEEE Computational Intelligence Magazine - November 2019 - 42
IEEE Computational Intelligence Magazine - November 2019 - 43
IEEE Computational Intelligence Magazine - November 2019 - 44
IEEE Computational Intelligence Magazine - November 2019 - 45
IEEE Computational Intelligence Magazine - November 2019 - 46
IEEE Computational Intelligence Magazine - November 2019 - 47
IEEE Computational Intelligence Magazine - November 2019 - 48
IEEE Computational Intelligence Magazine - November 2019 - 49
IEEE Computational Intelligence Magazine - November 2019 - 50
IEEE Computational Intelligence Magazine - November 2019 - 51
IEEE Computational Intelligence Magazine - November 2019 - 52
IEEE Computational Intelligence Magazine - November 2019 - 53
IEEE Computational Intelligence Magazine - November 2019 - 54
IEEE Computational Intelligence Magazine - November 2019 - 55
IEEE Computational Intelligence Magazine - November 2019 - 56
IEEE Computational Intelligence Magazine - November 2019 - 57
IEEE Computational Intelligence Magazine - November 2019 - 58
IEEE Computational Intelligence Magazine - November 2019 - 59
IEEE Computational Intelligence Magazine - November 2019 - 60
IEEE Computational Intelligence Magazine - November 2019 - 61
IEEE Computational Intelligence Magazine - November 2019 - 62
IEEE Computational Intelligence Magazine - November 2019 - 63
IEEE Computational Intelligence Magazine - November 2019 - 64
IEEE Computational Intelligence Magazine - November 2019 - 65
IEEE Computational Intelligence Magazine - November 2019 - 66
IEEE Computational Intelligence Magazine - November 2019 - 67
IEEE Computational Intelligence Magazine - November 2019 - 68
IEEE Computational Intelligence Magazine - November 2019 - 69
IEEE Computational Intelligence Magazine - November 2019 - 70
IEEE Computational Intelligence Magazine - November 2019 - 71
IEEE Computational Intelligence Magazine - November 2019 - 72
IEEE Computational Intelligence Magazine - November 2019 - 73
IEEE Computational Intelligence Magazine - November 2019 - 74
IEEE Computational Intelligence Magazine - November 2019 - 75
IEEE Computational Intelligence Magazine - November 2019 - 76
IEEE Computational Intelligence Magazine - November 2019 - 77
IEEE Computational Intelligence Magazine - November 2019 - 78
IEEE Computational Intelligence Magazine - November 2019 - 79
IEEE Computational Intelligence Magazine - November 2019 - 80
IEEE Computational Intelligence Magazine - November 2019 - 81
IEEE Computational Intelligence Magazine - November 2019 - 82
IEEE Computational Intelligence Magazine - November 2019 - 83
IEEE Computational Intelligence Magazine - November 2019 - 84
IEEE Computational Intelligence Magazine - November 2019 - 85
IEEE Computational Intelligence Magazine - November 2019 - 86
IEEE Computational Intelligence Magazine - November 2019 - 87
IEEE Computational Intelligence Magazine - November 2019 - 88
IEEE Computational Intelligence Magazine - November 2019 - 89
IEEE Computational Intelligence Magazine - November 2019 - 90
IEEE Computational Intelligence Magazine - November 2019 - 91
IEEE Computational Intelligence Magazine - November 2019 - 92
IEEE Computational Intelligence Magazine - November 2019 - Cover3
IEEE Computational Intelligence Magazine - November 2019 - Cover4
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202311
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202308
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202305
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202302
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202211
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202208
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202205
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202202
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202111
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202108
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202105
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202102
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202011
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202008
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202005
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_202002
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201911
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201908
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201905
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201902
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201811
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201808
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201805
https://www.nxtbook.com/nxtbooks/ieee/computationalintelligence_201802
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter17
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall17
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_summer17
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_spring17
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter16
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall16
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_summer16
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_spring16
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter15
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall15
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_summer15
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_spring15
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter14
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall14
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_summer14
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_spring14
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter13
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall13
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_summer13
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_spring13
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_winter12
https://www.nxtbook.com/nxtbooks/ieee/computational_intelligence_fall12
https://www.nxtbookmedia.com