trainTest: Separate featureMatrix into Train and Test sets

Description Usage Arguments Value

View source: R/PSB_functions.R

Description

This function takes the data.frame generated from featureMatrix and separates the data.frame in two Train and Test sets for cross-validation.

Usage

1
2
3
4
5
6
7
trainTest(
  featureMatrix,
  positive.label = 1,
  negative.label = 0,
  testFold = 5,
  labelAsFactor = TRUE
)

Arguments

featureMatrix

The data.frame that featureMatrix function outputs.

positive.label

The positive label used in featureMatrix function.

negative.label

The negative label used in featureMatrix function.

testFold

Portion of data.frame to be used as Test set.

labelAsFactor

Set the column of Label into factors.

Value

A list containing the Train and Test sets. no.Aug attribute contains the number of base and augmented sample in each group.


ShaoxunLiu/proteinStructureBoost documentation built on Dec. 18, 2021, 1:05 p.m.