Learn R Programming

ai (version 1.0.4.44)

prodata: Data processing

Description

The prodata function generates an data list for models. It additionally splits data for training and testing set by split ratio.

Usage

prodata(data, status_colname, SplitRatio = 0.75)

Value

data list

Arguments

data

data.frame with data to be modeled

status_colname

name of the column in data where the true results (true positive, expected) values are listed

SplitRatio

Splitting ratio; 0.75 means 75% data for training and 25% for testing, more: sample.split

Examples

Run this code
# \donttest{

model_data <- data.frame(a = c(1,2,3,4,5,6),
                         b = c(1,2,3,4,5,6),
                         s = c(1,2,3,4,5,6))

prodata(data = model_data, status_colname = "s")

# }

Run the code above in your browser using DataLab