Skip to content

Commit e5c7f92

Browse files
authored
document xgboost case weight support (#1101)
1 parent dc9a66e commit e5c7f92

File tree

3 files changed

+22
-0
lines changed

3 files changed

+22
-0
lines changed

man/details_boost_tree_xgboost.Rd

Lines changed: 10 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

man/rmd/boost_tree_xgboost.Rmd

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,11 @@ xgboost does not have a means to translate factor predictors to grouped splits.
6060

6161
For classification, non-numeric outcomes (i.e., factors) are internally converted to numeric. For binary classification, the `event_level` argument of `set_engine()` can be set to either `"first"` or `"second"` to specify which level should be used as the event. This can be helpful when a watchlist is used to monitor performance from with the xgboost training process.
6262

63+
## Case weights
64+
65+
```{r child = "template-uses-case-weights.Rmd"}
66+
```
67+
6368
## Other details
6469

6570
### Interfacing with the `params` argument

man/rmd/boost_tree_xgboost.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,13 @@ xgboost does not have a means to translate factor predictors to grouped splits.
109109

110110
For classification, non-numeric outcomes (i.e., factors) are internally converted to numeric. For binary classification, the `event_level` argument of `set_engine()` can be set to either `"first"` or `"second"` to specify which level should be used as the event. This can be helpful when a watchlist is used to monitor performance from with the xgboost training process.
111111

112+
## Case weights
113+
114+
115+
This model can utilize case weights during model fitting. To use them, see the documentation in [case_weights] and the examples on `tidymodels.org`.
116+
117+
The `fit()` and `fit_xy()` arguments have arguments called `case_weights` that expect vectors of case weights.
118+
112119
## Other details
113120

114121
### Interfacing with the `params` argument

0 commit comments

Comments
 (0)