predictors

0th

Percentile

List predictors used in the model

This class uses a model fit to determine which predictors were used in the final model.

Keywords
models
Usage
predictors(x, ...)

## S3 method for class 'train': predictors(x, ...)

## S3 method for class 'terms': predictors(x, ...)

## S3 method for class 'formula': predictors(x, ...)

## S3 method for class 'list': predictors(x, ...)

## S3 method for class 'mvr': predictors(x, ...)

## S3 method for class 'gbm': predictors(x, ...)

## S3 method for class 'Weka_classifier': predictors(x, ...)

## S3 method for class 'fda': predictors(x, ...)

## S3 method for class 'earth': predictors(x, ...)

## S3 method for class 'gausspr': predictors(x, ...)

## S3 method for class 'ksvm': predictors(x, ...)

## S3 method for class 'lssvm': predictors(x, ...)

## S3 method for class 'rvm': predictors(x, ...)

## S3 method for class 'train': predictors(x, ...)

## S3 method for class 'gpls': predictors(x, ...)

## S3 method for class 'knn3': predictors(x, ...)

## S3 method for class 'LogitBoost': predictors(x, ...)

## S3 method for class 'lda': predictors(x, ...)

## S3 method for class 'rda': predictors(x, ...)

## S3 method for class 'multinom': predictors(x, ...)

## S3 method for class 'nnet': predictors(x, ...)

## S3 method for class 'pcaNNet': predictors(x, ...)

## S3 method for class 'NaiveBayes': predictors(x, ...)

## S3 method for class 'randomForest': predictors(x, ...)

## S3 method for class 'pamrtrained': predictors(x, newdata = NULL, threshold = NULL, ...)

## S3 method for class 'superpc': predictors(x, newdata = NULL, threshold = NULL, n.components = NULL, ...)

## S3 method for class 'slda': predictors(x, ...)

## S3 method for class 'rpart': predictors(x, surrogate = TRUE, ...)

## S3 method for class 'regbagg': predictors(x, surrogate = TRUE, ...)

## S3 method for class 'classbagg': predictors(x, surrogate = TRUE, ...)

## S3 method for class 'glmboost': predictors(x, ...)

## S3 method for class 'gamboost': predictors(x, ...)

## S3 method for class 'blackboost': predictors(x, ...)

## S3 method for class 'BinaryTree': predictors(x, surrogate = TRUE, ...)

## S3 method for class 'RandomForest': predictors(x, surrogate = TRUE, ...)

## S3 method for class 'bagEarth': predictors(x, ...)

## S3 method for class 'bagFDA': predictors(x, ...)

## S3 method for class 'ppr': predictors(x, ...)

## S3 method for class 'rfe': predictors(x, ...)

Arguments
x
a model object, list or terms
newdata
for pamr.train and superpc.train: the training data
threshold
for pamr.train and superpc.train: the feature selection threshold
n.components
for superpc.train: the number of PCA components used
surrogate
a logical for rpart, ipredbagg, ctree and c
...
not currently used
Details

For randomForest, cforest, ctree, rpart, ipredbagg, bagging, earth, fda, pamr.train, superpc.train, bagEarth and bagFDA, an attempt was made to report the predictors that were actually used in the final model.

In cases where the predictors cannot be determined, NA is returned. For example, nnet may retrun missing values form predictors.

Value

  • a character string of predictors or NA.

Aliases
  • predictors
  • predictors.BinaryTree
  • predictors.LogitBoost
  • predictors.NaiveBayes
  • predictors.RandomForest
  • predictors.Weka_classifier
  • predictors.bagEarth
  • predictors.bagFDA
  • predictors.blackboost
  • predictors.classbagg
  • predictors.earth
  • predictors.fda
  • predictors.formula
  • predictors.gamboost
  • predictors.gausspr
  • predictors.gbm
  • predictors.glmboost
  • predictors.gpls
  • predictors.knn3
  • predictors.ksvm
  • predictors.lda
  • predictors.list
  • predictors.lm
  • predictors.lssvm
  • predictors.multinom
  • predictors.mvr
  • predictors.nnet
  • predictors.pamrtrained
  • predictors.pcaNNet
  • predictors.ppr
  • predictors.randomForest
  • predictors.rda
  • predictors.regbagg
  • predictors.rpart
  • predictors.rvm
  • predictors.slda
  • predictors.superpc
  • predictors.terms
  • predictors.train
  • predictors.rfe
Documentation reproduced from package caret, version 4.25, License: GPL-2

Community examples

Looks like there are no examples yet.