Skip to content

Instantly share code, notes, and snippets.

@noleto
Created August 6, 2018 12:58
Show Gist options
  • Save noleto/85643da1f7d7e5d5ca43a2308bc4d2f9 to your computer and use it in GitHub Desktop.
Save noleto/85643da1f7d7e5d5ca43a2308bc4d2f9 to your computer and use it in GitHub Desktop.
Plot High Resolution XGBoost Tree
xgb.plot_tree(booster, num_trees=1, rankdir='LR')
fig = matplotlib.pyplot.gcf()
fig.set_size_inches(80, 20)
fig.savefig('tree.png')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment