Skip to main content

A Decision Tree Visualization Packages.


# import dtreeplot package model_plot function  


from dtreeplot import model_plot  

from sklearn import datasets  
from sklearn.tree import DecisionTreeClassifier   

X, y = datasets.make_classification(n_samples=30000, n_features=10, weights=[0.96, 0.04])  
features = [f'Var{i+1}' for i in range(X.shape[1])]  


clf = DecisionTreeClassifier(criterion='gini',  
                             max_depth=3,   
                             min_samples_split=30,   
                             min_samples_leaf=10,   
                             random_state=1234)  
model = clf.fit(X, y)  

# visualize tree model  
model_plot(model, features, labels=y, height=530)  
pip3 install dtreeplot --upgrade

Metadata

Release files for dtreeplot 0.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for dtreeplot 0.1.2
File Interpreter ABI Platform Actions
dtreeplot-0.1.2-py3-none-any.whl Python 3 none any Details for dtreeplot-0.1.2-py3-none-any.whl

Release files / dtreeplot-0.1.2-py3-none-any.whl

Download URL dtreeplot-0.1.2-py3-none-any.whl
Size 98.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ae29a638c54eb0b6bf15c4fdd09f4d0747ae7148297b9efbc50b81045936d9de
BLAKE2b-256 checksum
How to use checksums
d1660773a4672c2dcb854234ff737164618e3387d87f6ec4bf9f9bae795fe949
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.4.1 importlib_metadata/4.5.0 pkginfo/1.7.0 requests/2.24.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.7.3

Security for dtreeplot 0.1.2

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page