Create class-balanced case-control groups for classification models
Source:R/classification_models.R
make_groups.Rd
make_groups()
creates class-balanced case-control groups for classification models.
It separates the data into control and case groups. It then calculates the amount of data
from each case in the control group and randomly selects the number of each control class samples.
It also filters the control data of sex specific cases.
Usage
make_groups(
join_data,
variable = "Disease",
case,
cases,
only_female = NULL,
only_male = NULL,
seed = 123
)