## 2 Material and Methods
### Feature Extraction and Selection
#### 2.2.3 Correlation Analysis  
The tsfresh and PCA eliminate calculated time-series features based on hypothesis testing (feature vs target significance) and explain the variance of the features. For a classification problem, it is vital to remove the highly correlated features as they can introduce bias in the training of the model, make the model computationally expensive (as the model learns the same information after skimming several different correlated features), reduce the precision of coefficient estimation, and affect the interpretability [44; 45]. Thus, this study recommends correlation analysis to ensure the selection of weakly correlated, well-distinguishable features for an accurate, precise, and easily interpretable classification model. The three commonly used methods for correlation analysis are described below.  
The Pearson correlation coefficient [46; 47] is a statistical test that measures the ratio between the covariance of two features and their standard deviations. The coefficients show the magnitude of correlation/association and the direction (positive or negative) of  
Figure 3: Stages of feature extraction and feature selection. The tsfresh library calculates and shortlists the hundreds of time-series features, PCA is applied to reduce the feature dimension; to select well-distinguishable features, correlation coefficients are calculated using the three methods.  
the relationship. The value of the Pearson coefficient varies between \(-1\) and \(+1\), and is calculated as:  
\[r=\frac{\sum(x_{i}-\overline{x})(y_{i}-\overline{y})}{\sqrt{\sum(x_{i}-\overline {x})^{2}(y_{i}-\overline{y})^{2}}} \tag{1}\]  
In Equation (1), \(r\) is the Pearson correlation coefficient, \(x_{i}\) and \(y_{i}\) is the \(i\) the value of two features, while \(\overline{x}\) and \(\overline{y}\) is the mean value of the \(x\) and \(y\) features.  
Spearman Ranking Correlation Coefficient  
The Spearman ranking correlation [48; 49] is a statistical test that measures how closely two features fluctuate. The features are ranked based on their similarity and dissimilarity, and then correlation/association between the features is calculated using the following equation (Equation (2)):  
\[\rho=1-\frac{6\sum{d_{i}}^{2}}{n(n^{2}-1)} \tag{2}\]  
where \(\rho\) is the Spearman coefficient, \(d_{i}\) is the difference between each feature rank, while \(n\) is the total number of observations. The value of the Spearman coefficient also varies between \(-1\) to \(+1\).  
Kendall Ranking Correlation Coefficient  
Kendall ranking correlation [50; 51] analysis is a statistical method of measuring the rank association of the two measured features. The correlation is determined based on the concordance and discordance values, and is determined as:  
\[\tau=\frac{2\left(n_{c}-n_{d}\right)}{n(n-1)} \tag{3}\]  
In Equation (3), \(\tau\) is the Kendall coefficient, \(n_{c}\) is the number of concordant values (i.e., \(x_{2}-x_{1}\) and \(y_{2}-y_{1}\) have the same sign), \(n_{d}\) is the number of discordant values (i.e., \(x_{2}-x_{1}\) and \(y_{2}-y_{1}\) have an opposite sign), while \(n\) is the total number of observations and \(x\),\(y\) are the two features. The correlation coefficient calculated using the Kendall method could vary between \(-1\) and \(+1\).  
Table 3 provides a guideline [52] on the interpretation of the correlation coefficient and the association of features with each other. In this study, all the features with a correlation coefficient between \(-0.4\) to \(0.4\) were chosen for further analysis.