title: K-means clustering on data set with mixed data using Scikit-learn
body: <p>I am experimenting with machine learning algorithms and have a pretty large data set containing both numerical and categorical data. I followed this post here: <a href="http://www.ritchieng.com/machinelearning-one-hot-encoding/" rel="nofollow noreferrer">http://www.ritchieng.com/machinelearning-one-hot-encoding/</a> to encode categorical features to numerical: </p>
  
  <p>I want to try K-means clustering of the whole data set for instance. I am not sure how to use this encoded data array I have now as a part of the original data frame in order to run machine learning algorithms. I would really appreciate an example.</p>