setRandomForest: Create setting for random forest model with python (very...

Description Usage Arguments Examples

View source: R/RandomForest.R

Description

Create setting for random forest model with python (very fast)

Usage

1
2
3
4
5
6
7
setRandomForest(
  mtries = -1,
  ntrees = 500,
  maxDepth = c(4, 10, 17),
  varImp = T,
  seed = NULL
)

Arguments

mtries

The number of features to include in each tree (-1 defaults to square root of total features)

ntrees

The number of trees to build

maxDepth

Maximum number of interactions - a large value will lead to slow model training

varImp

Perform an initial variable selection prior to fitting the model to select the useful variables

seed

An option to add a seed when training the final model

Examples

1
2
3
4
5
## Not run: 
model.rf <- setRandomForest(mtries=c(-1,5,20),  ntrees=c(10,100), 
                           maxDepth=c(5,20))

## End(Not run)                           

hxia/plp-git-demo documentation built on March 19, 2021, 1:54 a.m.