Abstract
As the huge dimensionality of textual data restrains the classification accuracy, it is essential to apply feature selection (FS) methods as dimension reduction step in text classification (TC) domain. Most of the FS methods for TC contain several number of probabilities. In this study, we proposed a new FS method named as Extensive Feature Selector (EFS), which benefits from corpus-based and class-based probabilities in its calculations. The performance of EFS is compared with nine well-known FS methods, namely, Chi-Squared (CHI2), Class Discriminating Measure (CDM), Discriminative Power Measure (DPM), Odds Ratio (OR), Distinguishing Feature Selector (DFS), Comprehensively Measure Feature Selection (CMFS), Discriminative Feature Selection (DFSS), Normalised Difference Measure (NDM) and Max–Min Ratio (MMR) using Multinomial Naive Bayes (MNB), Support-Vector Machines (SVMs) and k-Nearest Neighbour (KNN) classifiers on four benchmark data sets. These data sets are Reuters-21578, 20-Newsgroup, Mini 20-Newsgroup and Polarity. The experiments were carried out for six different feature sizes which are 10, 30, 50, 100, 300 and 500. Experimental results show that the performance of EFS method is more successful than the other nine methods in most cases according to micro-F1 and macro-F1 scores.
1. Introduction
Owing to the use of Internet and electronic devices, digital text documents increased rapidly. With the increase in these textual data, it is necessary to classify them according to their content in order to benefit from these data. The smallest constituent of text documents is word which plays an important role in classification of text documents [1,2]. Text classification (TC) – especially studied in computer science, information retrieval and information science – has found different applications in various domains such as genre classification [3], spam e-mail filtering [4], short message service (SMS) spam filtering [5], author identification [6], topic detection [7], medical document classification [8–11] and web page classification [12].
Generally, TC contains several steps which are pre-processing, feature extraction, feature selection (FS), feature weighting and classification. As a pre-processing step, tokenisation, stop-word removal, lower-case conversion and stemming techniques are utilised for improving the performance of the classification [13]. The processed tokens are employed to build a list of the features for the textual data. Bag-of-words (BoWs) and vector space model are utilised in order to realise feature extraction step [14]. Then, vector space is created according to the frequency of these features. In this vector space, each term forms a dimension. Even an ordinary text, data set consists of hundreds of thousands of features. The high-dimension vector space is compelling, and the size of this vector space needs to be reduced. While doing this operation, a FS method is required to add the important features to the vector space. During feature weighting step, term frequency–inverse document frequency (TF–IDF) is one of the most used weighting methods [15].
FS methods are generally classified into three different categories [16]. These are filters, wrappers and embedded methods. While filters do not require any classification algorithm in its flow, wrappers and embedded methods need a classification algorithm during the construction of the final feature subset. Requirement of any classification algorithm may increase running time during the selection of feature subset. Because of these reasons, filter-based FS methods are mostly preferred than wrappers and embedded methods.
In this study, a new filter FS method named as the Extensive Feature Selector (EFS) is proposed for TC. The method has been proposed considering the class-based and corpus-based discrimination of the feature. So, class-based probabilities and corpus-based probabilities are utilised for selecting more distinctive features. According to the experimental results presented in the next parts of the study, the proposed method is more successful than the other state-of-the-art methods in terms of macro-F1 and micro-F1 in most cases.
The rest of this study is organised as follows. In section 2, related works about FS methods are summarised. FS methods that are compared with EFS method are briefly described in section 3. The proposed method is explained in section 4 in detail. In section 5, we described experimental settings consisting of data sets, classifiers, success measures, similarity analysis and accuracy analysis. Finally, a conclusion is given in section 6.
2. Related works
In the literature, there are many studies related to filter-based FS methods, FS schemes and two-stage schemes including the combination of filter-based and wrapper-based techniques in TC domain. Filter FS methods are commonly preferred thanks to low processing time. Document frequency [17], information gain [18], mutual information [19], improved Gini index [20] and deviation from Poisson’s distribution [21] are some examples to filter-based FS methods. Uysal and Gunal [22] proposed a new FS method, namely, Distinguishing Feature Selector (DFS). While DFS assigns high scores to discriminative features, it assigns low scores to irrelevant features according to some pre-defined criteria. Yang et al. [23] presented a novel FS technique, namely, Comprehensively Measure Feature Selection (CMFS). CMFS computes the importance of a feature considering both inter-class and intra-class distributions. Experimental studies showed that CMFS is more successful than six FS techniques on three benchmark data sets using two classification algorithms. Zong et al. [24] proposed a new FS method, namely, discriminative feature selection (DFSS) which takes into account both the correlation between terms and classes and the semantic similarity between terms and documents. Experimental works showed that the performance of DFSS is competitive with other FS techniques. Rehman et al. proposed several FS methods for TC [25–27]. Rehman et al. [27] proposed a novel FS method, namely, relative discrimination criterion (RDC) which takes into account feature counts. RDC is more successful than four different FS metrics on four public data sets using two classifiers. In a study [25], they proposed a novel FS method, namely, Normalised Difference Measure (NDM) which considers the relative document frequencies. NDM is more successful than traditional FS algorithms on different data sets using some classifiers. In addition to this study, they proposed a different new FS technique [26], namely, Max–Min Ratio (MMR) which selects smaller subsets of more informative features even in data sets including highly skewed categories. Kim and Zzang [28] proposed a novel filter-based FS technique called as Trigonometric Comparison Measure (TCM) taking into account relative document frequencies. The method uses true positive rate and false positive rate to determine informative terms for improving the performance of classification. In experiments, the method was compared with eight successful filter-based FS methods on 10 data sets with two classifiers. Experimental studies showed that TCM is more successful than other methods for TC. Pinheiro et al. [29] proposed a filter-based FS method, namely, ALOFT (At Least One FeaTure) which considers specific characteristics of TC domain. The method guarantees that every document has at least one feature in the training set. Also, ALOFT can find out optimum features in a data-driven way. Experimental studies showed that the performance of the method is more successful than five FS methods on three public data sets with two classifiers. In addition to ALOFT, Pinheiro et al. [30] proposed two filter-based FS methods called as the Maximum f Features per Document (MFD) and the Maximum f Features per Document-Reduced (MFDR) for TC domain. These methods guarantee that each document contributes to the final feature set. Experimental studies showed that the proposed methods give better performance than Variable Ranking and ALOFT algorithms with three FS methods on four benchmark data sets using the Naive Bayes classifier.
In addition to filter-based FS methods, there are several FS schemes in the literature [1,2]. In filter-based FS schemes, features are assigned to a score based on their distinguishing power. These features are then sorted in descending order according to their scores. At the last stage, the best N features are selected. Uysal [1] proposed an improved global feature selection scheme (IGFSS) which modifies the standard FS scheme to obtain more informative feature set representing each class equally. Using a local FS method, a label is assigned to each feature taking into account the distinguishing powers of the features in the classes. While some of the classes are represented in a good way by the selected features, several classes may not be represented well. In order to fix this situation, IGFSS constructs the feature set by selecting equal number of features representing each class. Based on this study, a new scheme using variable number of features representing each class during feature set construction process was proposed by Agnihotri et al. [2]. They stated that using equal number of features creates problems in multi-class unbalanced data sets. If an equal number of features are taken from each class, some important features in classes may not be not selected. To solve this problem, based on the distribution of the features in the classes, a variable number of features were selected from each class. Agnihotri et al. [31] proposed a novel Soft Voting Technique (SVT) in order to overcome some shortcomings of IGFSS. SVT utilised the weighted average of three methods such as Odds Ratio (OR), Correlation Coefficient (CC) and Galavotti–Sebastiani–Simi (GSS) Coefficient. The SVT was compared through four classifiers applied on five benchmark data sets. Experimental studies showed that SVT attains an important improvement on classification performance in comparison to standard techniques.
Furthermore, many hybrid methods by combining filters and wrappers have been proposed [32–34]. Uysal and Gunal [32] proposed an approach, namely, genetic algorithm oriented latent semantic features (GALSF), which consists of FS methods and feature transformation stages. First, filter-based methods were applied for selecting a subset of features. Second, latent semantic indexing (LSI) empowered by genetic algorithm was employed. Experimental studies showed that GALSF obtains better performance than both LSI and filter-based FS techniques on public data sets for different feature sizes. Ghareb et al. [33] proposed a hybrid FS technique based on genetic algorithm (GA). The technique utilises a hybrid technique which takes advantage of both filter-based methods and enhanced GA to solve high dimension of the feature size and increase classification performance. The experimental results showed that hybrid approaches give better performance than only filter-based methods for dimension reduction stage. Uysal [34] analysed two-stage FS methods which consists of local FS methods, feature transformation and wrapper-based FS methods. In this study, four local FS methods were utilised in conjunction with three feature construction techniques named as maximum globalisation technique (MAX), weighted averaging globalisation technique (AVG) and selecting equal number of features for each class (EQ). Then, principal component analysis (PCA), LSI and GA were used. According to experimental results, AVG and EQ methods generally obtained better performance than MAX method. Also, PCA was more successful than LSI and GA methods in feature transformation stage.
3. FS methods
There are many filter-based FS methods in TC domain. In this study, nine filter methods for FS stage were employed. These methods are CHI2, CDM, DPM, OR, DFS, CMFS, DFSS, NDM and MMR. Tables 1 and 2 express some common notations about FS methods for TC.
Contingency table of term t and class
Preliminary notations for FS methods.
3.1. CHI2
As a popular FS method, CHI2 [22] method computes divergence from the distribution expected if one regards occurrence of the feature t is independent of the class
CHI2 score of a feature is computed for each class, and it is necessary to globalise class-based scores in order to obtain a unique score for each feature. There are three methods named as which are sum, weighted sum and maximum to globalise this score. In this study, weighted average is preferred to globalise CHI2 score as follows
3.2. CDM
CDM derives from OR proposed by Chen et al. [35]. CDM method is much simpler than Multi-Class Odds Ratio (MC-OR). CDM is better than MC-OR according to performance. The formula of the method is as follows
3.3. DPM
DPM focuses on both positive and negative distinguishing features. Also, the method has low computation time [36]. The aim of DPM method is to select features which reveal larger differences among the classes. DPM selects higher distinctive features for TC. The formula of DPM can be defined as follows
3.4. MC-OR
Since the experiments were performed on multi-class data sets, MC-OR is utilised instead of the original OR [35] in this study. MC-OR method selects not only positive features but also negative features. The formula of the MC-OR method is as follows
3.5. DFS
DFS relies on the four pre-defined criteria. DFS selects informative features, while eliminating uninformative features taking into account certain requirements on feature characteristics. The formula of DFS [22] method is constituted as follows
3.6. CMFS
CMFS investigates the importance of a feature both in inter-class and intra-class, comprehensively [23]. The formula of CMFS method is as follows
3.7. DFSS
DFSS [24] selects features according to some criteria. These are selecting features with higher term frequency, higher occurrence rate and ignoring features occurring in all of the documents. DFSS selects features which are capable of discrimination between classes. According to these criteria, DFSS method is demonstrated as follows
This method was globalised by the maximum globalisation technique
3.8. NDM
NDM is developed by Rehman et al. [25] considering relative documents frequencies. Balanced Accuracy Measure [14] computes score of feature by taking the difference of its document frequency in the positive class and negative class. NDM is constructed by improving the Balanced Accuracy Measure. The formula of the method is defined as follows
3.9. MMR
Balanced Accuracy Measure treats two features having the same difference between document frequency in the positive class and negative class. Also, NDM can assign high score to highly uninformative sparse features in large and highly skewed text data sets. However, MMR is the improved version of Balanced Accuracy Measure and NDM. MMR gives better performance on data sets including highly skewed classes [26]. The method is combination of true positives, false positives and their differences. The method is demonstrated as follows
4. The proposed method
In this study, a new FS method has been proposed considering the class-based and corpus-based discrimination of the feature. It means that the proposed method computes the significance of a term from both class-based probabilities and corpus-based probabilities.
Considering the class-based discrimination of the feature:
If the term is more probably to be found in all documents within the class, the discrimination of the term for the relevant class increases; therefore, it must be assigned a high score.
If the term is more probably to be not found in some documents within the class, the discrimination of the term for the relevant class decreases; it must be assigned a low score.
If the term is more probably to be in other classes than the relevant class, the discrimination of the term decreases for the relevant class; it must be assigned a low score.
Based on the above requirements, the class-based discrimination score of the term is as follows
So, if the term is occurred in the documents in the relevant class, high score must be assigned. Similarly, if the term is not occurred in some of the documents in the relevant class, low score must be assigned. Also, if the term occurs in other classes, low score must be assigned. To assign a fair score, we added the calculated value to the numerator of the formula while it is added to the denominator of the formula to assign a low score. These three probabilities which are
Considering the corpus-based discrimination of the feature:
If the class is more probably to be in case of presence of term, the corpus-based discrimination of the feature increases; therefore, it must be assigned a high score.
If the class is less probably to be in case of presence of term, the corpus-based discrimination of the feature decreases; it must be assigned a low score.
If the class is more probably to be in case of absence of term, the corpus-based discrimination of the feature decreases; so, it must be assigned a low score.
Based on the above requirements, the corpus-based discrimination score of the term is as follows
So, if the probability of relevant class increases in case of presence of term, high score must be assigned. Similarly, if the probability of relevant class is low in case of absence of term, low score must be assigned. Also, the probability of relevant class is high in case of absence of term, low score is assigned. To assign a high score, we added the calculated value to the numerator of the formula while it is added to the denominator of the formula to assign a low score. These three probabilities which are
The class-based and the corpus-based scores range from 0.0 to 1.0. As we multiplied these two values by each other, the final score to be obtained is in the range 0.0–1.0. If we had added these two scores, the score would not have been in the 0.0–1.0 range and would have affected each other. Considering the class-based and the corpus-based discrimination of the feature, the formula of the proposed method EFS is as follows
The formula of the EFS method consists of two parts which are class-based and corpus-based. The value ranges of both parts are between 0 and 1. If the feature exists only in all documents of a single class, the values of both parts of the formula become ‘1.0’. So, the highest score for the feature is 1.0 by multiplying two parts of the formula. However, if the feature occurs in all documents of one class as well as in some classes, both class-based and corpus-based scores decrease. In addition, when class-based value is 0, corpus-based value cannot be different from 0 or vice versa. So, there is no damping of class-based and corpus-based scores each other.
EFS is similar to CMFS and DFS in some ways. The method resembles CMFS by multiplying the numerator of the class-based part and corpus-based part. Furthermore, the method resembles DFS with the denominator of the class-based part and the numerator of the corpus-based part. However, the formula of EFS is constructed after comprehensive studies. Experimental studies also reveal the success of the EFS method.
EFS has been studied extensively. Score assignment was made to make the feature more distinctive, considering both class-based probabilities and corpus-based probabilities. The final score was obtained by multiplying the class-based and corpus-based scores. Unlike the FS methods in the literature, EFS chooses distinctive features by considering many probabilities.
A sample collection is presented in Table 3 to show how EFS works. However, information about feature occurrences and scores assigned by EFS is given in Table 4.
Sample collection.
Information about feature occurrences and assigned scores.
In this sample collection, maximum score is assigned to ‘fish’ that occurs in all documents of only one class, namely, C1. Also, the features ‘mouse’ and ‘dog’ occur in two classes. Their scores are not equal because document frequency of the features is not the same. So, the feature ‘mouse’ is more distinctive than the feature ‘dog’ due to its occurrence in related classes. The feature ‘cat’ is the most uninformative feature because it occurs in all of the documents in three classes. As the feature ‘fish’ occurs in all documents of just one class, ‘cat’ occurs in all documents of all classes. While ‘fish’ is assigned to the highest score of 1.0, ‘cat’ is assigned the lowest score of 0.305 in this sample scenario. To sum up, EFS logically orders the features according to their class-based and corpus-based discriminating power as ‘fish’, ‘mouse’, ‘dog’ and ‘cat’. As seen in Table 5, CHI2 method ranked the features similar to EFS. So, EFS assigns fair scores to the features and EFS is a good FS method in terms of score assignment.
Feature scores for each FS method.
FS: Feature Selection; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; MC-OR: Multi-Class Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
In this method, we combined class-based and corpus-based discrimination. Thus, we have obtained more distinctive features. When we compare our method EFS with other methods, it can be stated that it chooses more distinctive features by calculating both corpus-based and class-based probabilities separately. Of course, some probabilities used while constructing the formula of the proposed method EFS are partially mentioned separately in some of the other methods. However, the proposed method EFS chooses features considering all the probabilities specified in its formula. The related results on the sample collection show how EFS method works. The performance of EFS is tested on different benchmark data sets in section 5.
5. Experimental studies
EFS was compared with the above-mentioned FS techniques in terms of feature similarity and accuracy. To perform this aim, four different data sets and two different success measures were utilised. The data sets and success measures used in the experiments are explained in the following subsections. Then, similarity ratios of top 10 selected features were presented before giving accuracy scores of all FS methods. Stop-word removal [13] and stemming [37] were carried out as pre-processing steps. Also, TF–IDF [1] was used during feature weighting step.
5.1. Data sets
It is inevitable to use data sets with different characteristics to demonstrate the performance of an FS method. So, experiments were carried out using four data sets which are single-labelled. The first data set is Reuters-21578 [38] which is one of the most utilised data sets in TC domain. In the experiments, we utilised the top 10 classes. The second data set is 20-Newsgroup [38] data set and 10 classes of this data set were utilised. The third data set is the Mini 20-Newsgroup [38] data set constructed using a subset of 20-Newsgroup. The final used data set is the Polarity data set containing movie reviews [39]. Further information about these four data sets is given in the Tables 6–9, respectively.
Reuters-21578 data set.
20-Newsgroup data set.
Mini 20-Newsgroup data set.
Polarity data set.
As shown in Tables 6–9, while Reuters-21578 is an unbalanced data set, 20-Newsgroup, Mini 20-Newsgroup and Polarity are the balanced data sets. In addition, train and test splits are pre-partitioned for Reuters data set, but 20-Newsgroup, Mini 20-Newsgroup and Polarity data sets are manually divided into train (70%) and test (30%) splits in the experiments.
5.2. Classifiers
TC is object to classifying uncategorised documents into pre-defined classes. TC aims constructing learning models from labelled documents and performs classification on unlabeled text documents using these models. In this study, we used three successful classifiers for TC domain [25]. These are Multinomial Naive Bayes, Support-Vector Machines (SVMs) and k-Nearest Neighbour (KNN) classifiers.
Multinomial Naive Bayes (MNB) is known as one of the most successful classifiers in TC domain. MNB is a special version of Naive Bayes classifier. While classical Naive Bayes models a document with the presence and absence of certain features, MNB [25] explicitly models it using feature counts. In TC studies, multinomial and multivariate Bernoulli event models are widely utilised. As MNB considers term frequencies, multivariate Bernoulli event model utilises document frequencies.
SVM is one of the most efficient classifiers in the TC studies. SVM classifier has two versions which are linear and non-linear [22]. We used linear version of SVM in this study. The important subject of SVM classifier is the margin concept. LIBSVM library [25] is utilised for SVM classifier with linear kernel.
KNN classifier is an efficient and simple learning algorithm [40]. It aims to estimate the class of test documents according to category information of the k-closest neighbours of the training documents in TC domain. The distance which is test documents and its neighbours can be computed by different metrics. Cosine similarity is utilised for finding similarity between test collection in the experimental studies. The value of k is determined from various values. KNN classifier is realised by setting k-value as 7 for all data sets.
5.3. Success measures
In this study, we used two success measures which are macro-F1- and micro-F1-measures [22] for the performance evaluation of FS methods.
The F1-measure takes into account both precision and recall. F1-measure is calculated separately for each class in macro-averaging, and then the average for all classes is computed [25]. In this situation, each class has same weight. Macro-F1 can be computed as follows
where
However, F1-measure is computed without class information in micro-averaging. Thus, all classification decisions are taken into account in text corpus. When evaluating unbalanced data sets, large categories could dominate small ones while computing micro-averaging. Micro-F1 can be computed as follows
where p and r correspond to the precision and the recall values for all classes.
Micro-F1-measure may not provide a fair evaluation for all cases because of dominating large classes. So, macro-F1-measure was used besides micro-F1 in the experiments.
5.4. Feature similarity analysis
Each FS method selects a feature subset according to its formula. Each feature is assigned a score according to discriminative power of it. Profile of feature subsets which are selected by FS algorithms can be tested with their classification performances. If informative features are assigned high scores by any FS method, the performance of classification obtained by those features will be higher. Likewise, if uninformative features are assigned low scores by any FS method, the classification accuracy of feature subset not including those features will probably be higher. On the contrary, if uninformative features are assigned high scores by any FS algorithm, the performance of classification obtained by those features will probably degraded. First, top 10 features selected by the proposed method are compared with the other methods in Tables 10–13 for each data set. In these tables, if a feature was not chosen by any other FS method at the same time, we would show it in bold. So, it can be stated that the features shown in bold are specific to an individual FS method. We can infer from the tables that the proposed method EFS selects common features selected by other nine FS methods used for comparison in general. One should note that these nine methods used for comparison are mostly state-of-the-art FS methods for TC. Therefore, constructing a feature set including so many distinct features which are very different from the other state-of-the-art FS methods may not make sense for a new method.
Top 10 selected features for Reuters-21578.
CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Top 10 selected features for 20-Newsgroup.
CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Top 10 selected features for Mini 20-Newsgroup.
CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Top 10 selected features for Polarity.
CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
5.5. Accuracy analysis
Different number of features selected by each FS technique was fed into MNB, SVM and KNN classifiers. Feature subsets were constructed using 10, 30, 50, 100, 300 and 500 features. Total number of features is 16867, 50419, 14244 and 21875 for Reuters-21578, 20-Newsgroup, Mini 20-Newsgroup and Polarity, respectively. Experimental results are shown in Tables 14–25. While the highest score was written in bold for corresponding feature size, we showed the highest score for the whole table both in bold and underlined. As seen in Tables 14–25, there is no unique method which is superior for all sizes with different data sets. However, EFS is more successful than all other methods in terms of the highest score in the tables.
Success measures for Reuters-21578 data set using MNB classifier.
MNB: Multinomial Naive Bayes; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Reuters-21578 data set using SVM classifier.
SVM: Support-Vector Machine; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Reuters-21578 data set using KNN classifier.
KNN: k-Nearest Neighbour; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for 20-Newsgroup data set using MNB classifier.
MNB: Multinomial Naive Bayes; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for 20-Newsgroup data set using SVM classifier.
SVM: Support-Vector Machine; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for 20-Newsgroup data set using KNN classifier.
KNN: k-Nearest Neighbour; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Mini 20-Newsgroup data set using MNB classifier.
MNB: Multinomial Naive Bayes; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Mini 20-Newsgroup data set using SVM classifier.
SVM: Support-Vector Machine; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Mini 20-Newsgroup data set using KNN classifier.
KNN: k-Nearest Neighbour; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Polarity data set using MNB classifier.
MNB: Multinomial Naive Bayes; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Polarity data set using SVM classifier.
SVM: Support-Vector Machine; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
Success measures for Polarity data set using KNN classifier.
KNN: k-Nearest Neighbour; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; OR: Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; EFS: Extensive Feature Selector.
For Reuters-21578 data set, the highest score was obtained with the EFS FS method in terms of micro-F1 and macro-F1 using MNB, SVM and KNN classifiers. However, EFS method has achieved the highest score only with MNB and KNN classifiers for 20-Newsgroup and Mini 20-Newsgroup data sets. Also, EFS method has achieved the highest score only with SVM and KNN classifiers for Polarity data set.
While the range of micro-F1 scores is between 0.553 and 0.928, the range of macro-F1 scores is between 0.122 and 0.705 for Reuters-21578 data set using MNB classifier. For MNB classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 300 features on Reuters-21578 data set are 0.928 and 0.705, respectively. It should be noted that EFS method also performed best for most feature sizes such as 30, 50, 100 and 300.
While the range of micro-F1 scores is between 0.761 and 0.927, the range of macro-F1 scores is between 0.150 and 0.670 for Reuters-21578 data set using SVM classifier. For SVM classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 500 features are 0.927 and 0.670 for Reuters-21578 data set, respectively. It should be noted that DFS also performed best for most feature sizes such as 30, 50 and 100. The proposed method EFS obtained the best performances in the other feature sizes such as 10 and 500.
While the range of micro-F1 scores is between 0.756 and 0.905, the range of macro-F1 scores is between 0.157 and 0.603 for Reuters-21578 data set using KNN classifier. For KNN classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 50 features are 0.905 and 0.603 for Reuters-21578 data set, respectively. It should be noted that DFS, DFSS and MMR also performed best for different feature sizes such as 30, 100, 300 and 500. Also, it is possible to conclude that MNB classifier is more efficient than SVM and KNN classifiers on Reuters-21578 data set in terms of the highest performances.
While the range of micro-F1 scores is between 0.182 and 0.976, the range of macro-F1 scores is between 0.018 and 0.953 for 20-Newsgroup data set using MNB classifier. For MNB classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 30 features on 20-Newsgroup data set are 0.976 and 0.953, respectively. It should be noted that EFS also performed best only with two feature dimensions which are 30 and 50.
While the range of micro-F1 scores is between 0.182 and 0.988, the range of macro-F1 scores is between 0.018 and 0.979 for 20-Newsgroup data set using SVM classifier. For SVM classifier, the highest the micro-F1 score and macro-F1 score which were obtained with NDM method using 500 features are 0.988 and 0.979 on 20-Newsgroup data set, respectively. It should be noted that different methods such as CHI2, DPM, DFS, NDM, MMR and EFS also performed best for different feature sizes.
While the range of micro-F1 scores is between 0.182 and 0.962, the range of macro-F1 scores is between 0.100 and 0.936 for 20-Newsgroup data set using SVM classifier. For KNN classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 30 features are 0.962 and 0.936 on 20-Newsgroup data set, respectively. It should be noted that different methods such as DFS, DFSS, NDM, MMR and EFS also performed best for different feature sizes. Also, it is possible to conclude that SVM classifier is more efficient than MNB and KNN classifiers on 20-Newsgroup data set in terms of the highest performances.
While the range of micro-F1 scores is between 0.182 and 0.971, the range of macro-F1 scores is between 0.018 and 0.944 for Mini 20-Newsgroup data set using MNB classifier. For MNB classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 30 features are 0.971 and 0.944 on Mini 20-Newsgroup data set, respectively. It should be noted that EFS also performed best only for two feature sizes which are 30 and 50.
While the range of micro-F1 scores is between 0.182 and 0.981, the range of macro-F1 score values is between 0.018 and 0.963 for Mini 20-Newsgroup data set using SVM classifier. For SVM classifier, the highest the micro-F1 score and macro-F1 score which were obtained with NDM method using 300 features are 0.981 and 0.963 on Mini 20-Newsgroup data set, respectively. It should be noted that different methods such as CHI2, DFS, CMFS, NDM, MMR and EFS also performed best for different feature sizes.
While the range of micro-F1 scores is between 0.182 and 0.958, the range of macro-F1 score values is between 0.018 and 0.918 for Mini 20-Newsgroup data set using KNN classifier. For KNN classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 30 features are 0.958 and 0.918 on Mini 20-Newsgroup data set, respectively. It should be noted that different methods such as DFSS, NDM, MMR and EFS also performed best for different feature sizes. Also, it is possible to conclude that SVM classifier is more efficient than MNB and KNN classifiers on Mini 20-Newsgroup data set in terms of the highest performances.
While the range of micro-F1 scores is between 0.707 and 0.895, the range of macro-F1 scores is between 0.456 and 0.810 for Polarity data set using MNB classifier. For MNB classifier, the highest the micro-F1 score and macro-F1 score which were obtained with CHI2 method using 100 features are 0.895 and 0.810 on Polarity data set, respectively. It should be noted that EFS also performed best only for two feature sizes which are 300 and 500.
While the range of micro-F1 scores is between 0.704 and 0.886, the range of macro-F1 score values is between 0.464 and 0.795 for Polarity data set using SVM classifier. For SVM classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 500 features are 0.886 and 0.795 on Polarity data set, respectively. It should be noted that different methods such as DPM, DFS, DFSS, MMR and EFS also performed best for different feature sizes.
While the range of micro-F1 scores is between 0.701 and 0.853, the range of macro-F1 score values is between 0.441 and 0.742 for Polarity data set using KNN classifier. For KNN classifier, the highest the micro-F1 score and macro-F1 score which were obtained with EFS method using 100 features are 0.853 and 0.742 on Polarity data set, respectively. It should be noted that different methods such as CDM, DPM, DFS, DFSS, MMR and EFS also performed best for different feature sizes. Also, it is possible to conclude that MNB classifier is more efficient than SVM and KNN classifiers on Polarity data set in terms of the highest performances.
5.6. Statistical analysis
To show the validity of the proposed EFS method, t-test is utilised. Table 26 demonstrates the result of p-values from one-tailed, paired t-test.
Statistical significance of EFS method for (a) micro-F1 and (b) macro-F1 success measures with different classifiers.
EFS: Extensive Feature Selector; CHI2: Chi-Squared; CDM: Class Discriminating Measure; DPM: Discriminative Power Measure; MC-OR: Multi-Class Odds Ratio; DFS: Distinguishing Feature Selector; CMFS: Comprehensively Measure Feature Selection; DFSS: Discriminative Feature Selection; NDM: Normalised Difference Measure; MMR: Max–Min Ratio; MNB: Multinomial Naive Bayes; SVM: Support-Vector Machine; KNN: k-Nearest Neighbour.
The micro-F1 results showed that the performance gains obtained from the EFS method compared with CDM, MC-OR, CMFS, DFSS and NDM methods are statistically significant with rather high confidence with 90% levels for the MNB classifier. In addition, the performance gains obtained from EFS method compared with CDM, MC-OR, DFSS and NDM methods are statistically significant with rather high confidence with 90% levels for the SVM classifier. Also, the performance gains obtained from EFS method compared with CHI2, DPM, DFS, CMFS, DFSS and MMR methods are statistically significant with rather high confidence with 90% levels for the KNN classifier. The macro-F1 results showed that the performance gains obtained from the EFS method compared with CDM, MC-OR, CMFS, DFSS and NDM methods are statistically significant with rather high confidence with 90% levels for the MNB classifier. In addition, the performance gains obtained from EFS method compared with CHI2, CDM, MC-OR, CMFS, DFSS and NDM methods are statistically significant with rather high confidence with 90% levels for the SVM classifier. Also, the performance gains obtained from EFS method compared with DPM, DFS, CMFS, DFSS and MMR methods are statistically significant with rather high confidence with 90% levels for the KNN classifier. As seen in Table 26, almost all p-values except a few cases are at 90% level. These results confirm the success of the EFS method against other nine FS methods used for comparison.
6. Conclusion and future works
In this study, we proposed a new filter-based feature ranking approach called EFS for TC domain. Besides, we presented a comprehensive analysis of nine state-of-the-art FS methods in the literature. The proposed method EFS selects features according to class-based and corpus-based probabilities which contribute to determining distinctiveness of features. According to the experimental results, there is no method achieving the highest performance for all feature dimensions. However, EFS is more successful than other FS methods in terms of the highest scores on various data sets. The performance of EFS was compared with nine well-known filter-based FS techniques using different data sets, classifiers, success measures and statistical analysis. As a result, EFS is more successful than the others for most of the cases on each data set in terms of highest scores. As a future work, EFS may be applied to other domains in text mining problems.
Footnotes
Declaration of conflicting interests
The author(s) declared no potential conflicts of interest with respect to the research, authorship and/or publication of this article.
Funding
The author(s) received no financial support for the research, authorship and/or publication of this article.
