from dtreeviz.trees import dtreeviz # remember to load the package
viz = dtreeviz(tree_reg1, X_.values, y_['target_abs'].values,
target_name=["target_abs"],
feature_names=FITURES)
viz
from pydotplus import graph_from_dot_data
from sklearn.tree import export_graphviz
dot_data = export_graphviz(tree_reg1, filled=True, rounded=True,
feature_names=predictors,
out_file=None)
graph = graph_from_dot_data(dot_data)
graph.write_png('tree.png')
graph