Description Usage Arguments Details Value Author(s) References Examples
View source: R/interval_auc_1curve.R
Calculates the sample size, AUC, margin of error, or significance for the confidence interval of an Area Under the Curve (AUC). Assumes that the AUC is based on a single numeric predictor and that the AUC is normally distributed.
1 2 |
auc |
Observed Area Under the Curve (AUC) |
n |
Total sample size |
E |
Desired margin of error |
alpha |
Significance Level |
weights |
a list of length-2 vectors giving the
weights for the diseased and non-diseased groups. This
is used to calculate |
optim.max |
Maximum value for |
Exactly one of the parameters n
, E
,
auc
and alpha
must be passed as NULL
,
and that parameter will be calculated from the others.
Notice that alpha
has a non-NULL
default, so
NULL
must be explicitly passed if you want it
computed.
Returns a data frame of the parameters passed to the
function (expanded using expand.grid
) and the
corresponding sample size estimates.
E
: Margin of Error
auc
: Area Under the Curve (AUC)
k
:
Proportion of total sample size belonging to group 1
n1_est
: Exact sample size for group 1
n2_est
: Exact sample size for group 2
n_est
: Exact total sample size
n1
:
Estimated sample size for group 1 (next largest integer)
n2
: Estimated sample size for group 2 (next
largest integer)
n
: Estimated total sample
size (sum of n1
and n2
)
Benjamin Nutter
Nancy A Obuchowski, "Sample size calculations in studies of test accuracy," Statistical Methods in Medical Research 1998; 7: 371-392
James A. Hanley and Barbara J. McNeil, "The Meaning and Use of the Area under a Receiver Operating Characteristic (ROC) Curve," Radiology. Vol 143. No 1, Pages 29-36, April 1982.
1 2 3 4 5 | # (Example 1 from PASS Sample Size Software)
# \url{http://ncss.wpengine.netdna-cdn.com/wp-content/themes/ncss/pdf/Procedures/PASS/Confidence_Intervals_for_the_Area_Under_an_ROC_Curve.pdf}
interval_auc_1curve(auc=c(0.6, 0.7, 0.8, 0.9),
E = c(.05, .10),
alpha=0.05)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.