Learn R Programming

glmaag (version 0.0.6)

getcut: Get optimal cut points for binary or right censored phenotype

Description

Obtain optimal cut point based on Youden index for binary phenotype and log rank test for right censored phenotype.

Usage

getcut(pre, act, fam = "Logistic")

Arguments

pre

predicted value

act

actual values (class for binary phenotype and Surv object for right censored phenotype)

fam

the family of the outcome, can be "Gaussian", "Logistic" or "Cox"

Value

optimal cut point

Examples

Run this code
# NOT RUN {
x <- rnorm(100)
y <- as.numeric(x + rlogis(100) > 0)
getcut(x, y)
# }

Run the code above in your browser using DataLab