predx: Create a predx object.

View source: R/builders.R

predxR Documentation

Create a predx object.

Description

Creates a predx object storing extended predictions of caretx models with information concerning model type, class number and the type of prediction (training, cross-validation or test).

Usage

predx(
  data,
  classes = NULL,
  type = c("regression", "binary", "multi_class"),
  prediction = c("train", "cv", "test")
)

is_predx(x)

Arguments

data

a data frame with predictions, the columns .outcome and .fitted are obligatory.

classes

an optional character vector with class names.

type

model type (regression, binary or multi_class).

prediction

type of prediction (training, cv or test).

x

an object.

Details

The type argument describes the prediction type: regression, binary or multi_class.

Value

a predx object; is_predx() returns a logical value.

References

Kuhn M. Building predictive models in R using the caret package. J Stat Softw (2008) 28:1–26. doi:10.18637/jss.v028.i05


PiotrTymoszuk/caretExtra documentation built on Oct. 15, 2023, 10:03 p.m.