kroc(x1, x2, H1, h1, hy, gridsize, gridtype, xmin, xmax, supp=3.7, eval.points,
binned=FALSE, bgridsize, positive=FALSE, adj.positive, w, verbose=FALSE,
approx.ref="pmvnorm")## S3 method for class 'kroc':
summary(object, ...)
Hpi.kcde, hpi.kcde is called by default.kroc, output from krockroc which is a list
with fields:x1, x2 - same as inputeval.points In this set-up, the values in the first sample x1 should
be larger in general that those in the second sample x2.
If the bandwidth H1 is missing from kroc, then
the default bandwidth is the binned 2-stage plug-in selector
Hpi.kcde(, nstage=2, binned=TRUE). Likewise for
missing h1,hy. A bandwidth matrix H1 is required for
x1 for d>1, but the second bandwidth hy is always a
scalar since Y is a 1-d variable. These bandwidth selectors are optimal for cumulative
distribution/survival functions, see Duong (2013).
To compute the reference ROC curve, either kcde or
pmvnorm (from the kcde computation, whereas the
latter is a more exact computation of the multivariate normal CDF and
thus can give a smoother ROC curve.
Binning/exact estimation and positive 1-d data behaviour is the same
as for kde.
--The summary method for kroc objects prints out the
summary indices of the ROC curve, as contained in the indices field, namely
the AUC (area under the curve) and Youden index, see Duong (2013).
Lloyd, C. (1998) Using smoothed receiver operating curves to summarize and compare diagnostic systems. Journal of the American Statistical Association, 93, 1356--1364.
kcdesamp <- 1000
x <- rnorm.mixt(n=samp, mus=0, sigmas=1, props=1)
y <- rnorm.mixt(n=samp, mus=0.5, sigmas=1, props=1)
Rhat <- kroc(x1=x, x2=y)
summary(Rhat)Run the code above in your browser using DataLab