Feature selection for Machine Learning The data features used to train the machine learning model have a great impact on the ultimate performance. Irrelevant or partially relevant feature can negatively influence the model. The various automatic feature selection techniques are: Univariate Selection Recursive feature elimination Principal Component Analysis Feature Importance Benefits of feature selection techniques: Reduces overfitting Improves accuracy Reduces training time Univariate Selection: This selection can be used to select the features that have the strongest relationship with the output variable. The example below uses scikit-learn which provides SeleceKBest class that can be used combinely with chi-squared (chi2) statistical test for non-negative features to select 4 of the best features from the dataset(Pima Indian). Recursive Feature Elimination: REF works by recursively removing the attributes a...
Popular posts from this blog
Data visualization Univariate Plots(visualization at each attribute) Histograms Density Plots Box and Whisker Plots Histograms group data into bins and gives the count of observations in each bin. We can get an insight whether an attribute is Gaussian, skewed or has any exponential distribution. Density plot is another way of getting a quick idea of the distribution of each attribute We can also review the distribution using Box and Whisker Plots. Box plots summarize the distribution of each attribute, drawing a line for median and a box around 25th and 75th percentiles. The green line indicates the median or middle value. The whiskers give an idea of idea of the spread of the data and dots outside the whiskers shows the outlier values. Multivariate Plots(interactions between multiple variables) Correlation matrix Plot Scatter Plot matrix Correlation gives an indication of how related the change...
Comments
Post a Comment