Last active
July 24, 2020 20:11
-
-
Save vanbrands/8cc6b18970f5d6a896982f368ef30375 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from sklearn.preprocessing import OneHotEncoder | |
encoder = OneHotEncoder() | |
dummies = encoder.fit_transform(df['categorical_column']) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment