Reputation: 121
I am building a decision tree using scikit-learn and am exporting the resulting tree as a .dot file. However, the precision I am getting for each condition in each tree node is very low for numerical values. The numbers are rounded to four digits after the decimal point. Any ideas on how I could get better precision? Say 10 digits? THANKS
Upvotes: 0
Views: 61
Reputation: 28788
You can edit the export_graphvis function to change the %4f to just %f or any other precision. This function was meant for visualization, not really exchanging a predictor. There is a pull request with a json export IIRC, so if you want to store the tree to use it in another software, this might be more what you are looking for.
Upvotes: 1