Skip to content

Commit 5e75854

Browse files
committed
0.1.13
1 parent 53301f9 commit 5e75854

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

treeplot/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
__author__ = 'Erdogan Tasksen'
1010
__email__ = '[email protected]'
11-
__version__ = '0.1.12'
11+
__version__ = '0.1.13'
1212

1313
# module level doc-string
1414
__doc__ = """

treeplot/treeplot.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -50,15 +50,15 @@ def plot(model, featnames=None, num_trees=None, plottype='horizontal', figsize=(
5050
Figure axis of the input model.
5151
5252
"""
53-
modelname = str(model).lower()
53+
modelname = str(model).lower()[0:30]
5454
if ('xgb' in modelname):
5555
if verbose>=4: print('xgboost plotting pipeline.')
5656
ax = xgboost(model, featnames=featnames, num_trees=num_trees, figsize=figsize, plottype=plottype, verbose=verbose)
57+
elif ('lgb' in modelname):
58+
ax = lgbm(model, featnames=featnames, num_trees=num_trees, figsize=figsize, verbose=verbose)
5759
elif ('tree' in modelname) or ('forest' in modelname) or ('gradientboosting' in modelname):
5860
if verbose>=4: print('tree plotting pipeline.')
5961
ax = randomforest(model, featnames=featnames, num_trees=num_trees, figsize=figsize, verbose=verbose)
60-
elif ('lgb' in modelname):
61-
ax = lgbm(model, featnames=featnames, num_trees=num_trees, figsize=figsize, verbose=verbose)
6262
else:
6363
print('[treeplot] >Model not recognized: %s' %(modelname))
6464
ax = None

0 commit comments

Comments
 (0)