gainRatio {FSinR}R Documentation

The gain ratio measure

Description

Generates an evaluation function that calculates the gain ratio value (Quinlan 1986-Mar-01), using the information theory (set measure). This function is called internally within the filterEvaluator function.

Usage

gainRatio()

Value

Returns a function that is used to generate an evaluation set measure using the gain ratio value for the selected features.

Author(s)

Adan M. Rodriguez

References

Quinlan JR (1986-Mar-01). “Induction of decision trees.” Machine Learning, 1, 81–106. doi: 10.1007/BF00116251.

Examples

## Not run:  

## The direct application of this function is an advanced use that consists of using this 
# function directly to evaluate a set of features
## Classification problem

# A discrete dataset is used (in this case we use only several discrete columns)
adult <- adult[,c(4,9,10,15)]

# Generate the evaluation function with Cramer
gr_evaluator <- gainRatio()
# Evaluate the features (parameters: dataset, target variable and features)
gr_evaluator(adult,'income',c('race','sex','education'))

## End(Not run)

[Package FSinR version 2.0.5 Index]