Skip to content

Instantly share code, notes, and snippets.

@cuckookernel
Last active May 7, 2018 19:23
Show Gist options
  • Save cuckookernel/30666ee5e8719225f17cb4d97fb57d05 to your computer and use it in GitHub Desktop.
Save cuckookernel/30666ee5e8719225f17cb4d97fb57d05 to your computer and use it in GitHub Desktop.
rfc = RandomForestClassifier( n_estimators=100, max_depth=5 )
rfc.fit( train_df, train_Y)
train_pred = rfc.predict( train_df )
accuracy = (train_pred == train_Y).sum() / len( train_pred )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment