PreProcessingPredict: Preprocess the input for a new set of test objects for...

View source: R/HelperFunctions.R

PreProcessingPredictR Documentation

Preprocess the input for a new set of test objects for classifier

Description

The following actions are carried out: 1. data.frames are converted to matrix form and labels converted to integers 2. An intercept column is added if requested 3. centering and scaling is applied if requested.

Usage

PreProcessingPredict(modelform, newdata, y = NULL, classnames = NULL,
  scaling = NULL, intercept = FALSE)

Arguments

modelform

Formula object with model

newdata

data.frame object with objects

y

Vector or factor with class assignments (default: NULL)

classnames

Vector with class names

scaling

Apply a given z-transform to the design matrix X (default: NULL)

intercept

Whether to include an intercept in the design matrices

Value

list object with the following objects:

X

design matrix of the labeled data

y

integer vector indicating the labels of the labeled data


RSSL documentation built on May 29, 2024, 2:38 a.m.