Member-only story
How I won my ninth bronze medal with Kaggle using sklearn’s SelectKBest and LabelEncoder
This morning when I was getting ready to go to work, I checked my smart phone and noticed that I had an email from Kaggle. I was very surprised to find out that I have won my ninth bronze medal on a Kaggle competition. What I found to be particularly interesting is the fact that I had submitted my solution to the competition little more than twelve hours previously.
Although I will not win the competition because my score is not high enough, I think the judges were impressed because I had used Python’s machine learning library, sklearn, SelectKBest and LabelEncoder functions to obtain a prediction.
I used SelectKBest because I needed to reduce the number of features predicted upon in the hopes of decreasing redundant information so noise would in theory would be reduced and accuracy improved.
In addition I used LabelEncoder to encode the ten string classes in the label to numbers. When the test dataset had been predicted upon, I then reversed the encoding so I could submit the prediction in the manner that Kaggle wants.
Now that I have achieved bronze medal status, I must carry on studying machine learning techniques in an attempt to improve my accuracy so I will hopefully be awarded a silver medal in future competitions.
I have recorded a YouTube video with the code for this competition question, and the link can be found here:- https://www.youtube.com/watch?v=cJE9SvQNwVY