Skip to content

Commit

Permalink
Fix typo in Python Package Introduction (#2023)
Browse files Browse the repository at this point in the history
Fixed #2016
  • Loading branch information
ANtlord authored and terrytangyuan committed Feb 9, 2017
1 parent 4fb7fdb commit f054d81
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions doc/python/python_intro.md
Expand Up @@ -129,12 +129,12 @@ A model that has been trained or loaded can perform predictions on data sets.
# 7 entities, each contains 10 features
data = np.random.rand(7, 10)
dtest = xgb.DMatrix(data)
ypred = bst.predict(xgmat)
ypred = bst.predict(dtest)
```

If early stopping is enabled during training, you can get predictions from the best iteration with `bst.best_ntree_limit`:
```python
ypred = bst.predict(xgmat,ntree_limit=bst.best_ntree_limit)
ypred = bst.predict(dtest,ntree_limit=bst.best_ntree_limit)
```

Plotting
Expand Down

0 comments on commit f054d81

Please sign in to comment.