Learn R Programming

fifer (version 1.1)

rfInterp: Variable Selection with Random Forest

Description

Find best variables using Random Forest (Interpretation Step). Find complete documentation at rfThresh

Usage

rfInterp(object, nruns = 20, nsd = 1, importance = "permutation", ...)

Arguments

object
a rfThresh object
nruns
how many forests should be grown?
nsd
defaults to one.
importance
method of calculating importance (permutation or gini)
...
other arguments passed to cforest or randomForest

Value

varselect.interp
The variables selected for Interpretation (sorted)
err.interp
The error at each stage of the stepwise variable inclusion.
sd.min
The standard deviation of the minimum fitted value.
num.varselect.interp
The number of variables selected for interpretation.
comput.time
Computation time of the procedure.
data
The dataset used for fitting the RF algorithm
formula
The formula of all variables included after the interpretation step.

See Also

rfInterp, rfPred

Examples

Run this code
	#### do threshold step
## Not run: ------------------------------------
# data(iris); 
# data = iris; 
# formula = as.formula("Species ~ Sepal.Length + Sepal.Width + Petal.Length + Petal.Width")
# object = rfThresh(formula, data=iris, nruns=2, importance="gini"); 
# #### run interpretation step
# rfInterp(object, nruns=10, importance="permutation")
## ---------------------------------------------

Run the code above in your browser using DataLab