View source: R/oc_youden_normal.R
oc_youden_normal | R Documentation |
An optimal cutpoint maximizing the Youden- or J-Index (sensitivity + specificity - 1) is calculated parametrically assuming normal distributions per class.
oc_youden_normal( data, x, class, pos_class = NULL, neg_class = NULL, direction, ... )
data |
A data frame or tibble in which the columns that are given in x and class can be found. |
x |
(character) The variable name to be used for classification, e.g. predictions or test values. |
class |
(character) The variable name indicating class membership. |
pos_class |
The value of class that indicates the positive class. |
neg_class |
The value of class that indicates the negative class. |
direction |
(character) Use ">=" or "<=" to select whether an x value >= or <= the cutoff predicts the positive class. |
... |
To capture further arguments that are always passed to the method function by cutpointr. The cutpointr function passes data, x, class, metric_func, direction, pos_class and neg_class to the method function. |
Other method functions:
maximize_boot_metric()
,
maximize_gam_metric()
,
maximize_loess_metric()
,
maximize_metric()
,
maximize_spline_metric()
,
oc_manual()
,
oc_mean()
,
oc_median()
,
oc_youden_kernel()
data(suicide) oc_youden_normal(suicide, "dsi", "suicide", pos_class = "yes", neg_class = "no", direction = ">=") cutpointr(suicide, dsi, suicide, method = oc_youden_normal)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.