detecting redundant features using filters filters try to clean up the feature forest independent of any machine learning method used later they rely on statistical methods to find out which of the features are redundant (in which casewe need to keep only one per redundant feature groupor irrelevant in generalthe filter works as depicted in the workflow shown in the following diagramy all features xn select features that are not redundant some features xm select features that are not irrelevant resulting features correlation using correlationwe can easily see linear relationships between pairs of featureswhich are relationships that can be modeled using straight line in the graphs shown in the following screenshotwe can see different degrees of correlation together with potential linear dependency plotted as red dashed line ( fitted one-dimensional polynomialthe correlation coefficient at the top of the individual graphs is calculated using the common pearson correlation coefficient (the pearson valueby means of the pearsonr(function of scipy stat given two equal-sized data seriesit returns tuple of the correlation coefficient values and the -valuewhich is the probability that these data series are being generated by an uncorrelated system in other wordsthe higher the -valuethe less we should trust the correlation coefficient>from import scipy stats import pearsonr >pearsonr([ , , ][ , , ]>( >pearsonr([ , , ][ , , ]>( in the first casewe have clear indication that both series are correlated in the second onewe still clearly have non-zero value