# Feature selection method explanation

In the context of feature relevance, I am trying to understand the meaning of the correlation method for feature selection. Can somebody please explain if the following results of the correlation coefficients arise, then should I take that feature? The rule is to select the features for which corrcoeff values are greater than 0.5. Please correct me if wrong. The way I am calculating is using Matlab's corrcoeff(target,feature) where target and feature are vectors

Case1: corrcoeff returns NaN values --

Nan Nan
Nan  1


Should the feature be selected since the value is greater than 0.5?

Case2: corrcoeff returns 0 values

0 0
0  1


In this case, I should reject the feature.

Case3:

-0.3 0
0    -0.3


Negatively correlated but absolute values less than 0.5, so reject the feature

Case4: What if there is no linear relationship at all in which case corrcoeff will not work. How do I know if there is no linear relationship and in that case how to do feature selection; is there any other function or technique?

• Just some points, correlation matrix shouldn't be returned with NaN's, you might be doing wrong in some cases. In the third case, those -0.3 are the variance of first and second variable and 0 are the correlations, – Fatemeh Asgarinejad Jul 19 at 2:45