Learn R Programming

performanceEstimation (version 1.1.0)

responseValues: Obtain the target variable values of a prediction task

Description

This function obtains the values in the column whose name is the target variable of a prediction problem described by a formula.

Usage

responseValues(formula, data, na=NULL)

Arguments

formula
A formula describing a prediction problem
data
The data frame containing the data of the prediction problem
na
A function to handle NAs in the data

Value

A vector of values

References

Torgo, L. (2014) An Infra-Structure for Performance Estimation and Experimental Comparison of Predictive Models in R. arXiv:1412.0436 [cs.MS] http://arxiv.org/abs/1412.0436

Examples

Run this code
data(iris)
tgt <- responseValues(Species ~ ., iris)
summary(tgt)

Run the code above in your browser using DataLab