Closed RajdeepTarafder closed 1 year ago
from dtreeviz.trees import *
Import necessary libraries import dtreeviz # Visualize the decision tree using dtreeviz viz = dtreeviz(model, X, y, target_name='class', feature_names=iris.feature_names, class_names=iris.target_names.tolist())
NameError: name 'dtreeviz' is not defined
Please see https://github.com/parrt/dtreeviz. I think from dtreeviz.trees import * is wrong and other stuff. please use latest version as well :)
from dtreeviz.trees import *
Import necessary libraries import dtreeviz # Visualize the decision tree using dtreeviz viz = dtreeviz(model, X, y, target_name='class', feature_names=iris.feature_names, class_names=iris.target_names.tolist())
NameError: name 'dtreeviz' is not defined