Skip to content

Instantly share code, notes, and snippets.

@youssefHosni
Created September 2, 2023 00:19
Show Gist options
  • Save youssefHosni/838b4017356be4d0f221b1fdfece88db to your computer and use it in GitHub Desktop.
Save youssefHosni/838b4017356be4d0f221b1fdfece88db to your computer and use it in GitHub Desktop.
import xgboost as xgb
params = {"objective":"binary:logistic",'colsample_bytree': 0.3,'learning_rate': 0.1,
'max_depth': 5, 'alpha': 10}
model = xgb.XGBClassifier(**params)
model.fit(X_train, y_train)
model.fit(X_train, y_train)
model.score(X_test,y_test)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment