trinVUS.test: Trinormal VUS test

View source: R/trinVUS.test.R

trinVUS.testR Documentation

Trinormal VUS test

Description

A statistical test function to assess three-class ROC data. It can be used for assessment of a single classifier or comparison of two independent / correlated classifiers, using the statistical test developed by Xiong et al. (2007).

Usage

trinVUS.test(
  x1,
  y1,
  z1,
  x2 = 0,
  y2 = 0,
  z2 = 0,
  dat = NULL,
  paired = FALSE,
  conf.level = 0.95,
  alternative = c("two.sided", "less", "greater")
)

Arguments

x1, y1, z1

non-empty numeric vectors of data from the healthy, intermediate and diseased class from Classifier 1.

x2, y2, z2

numeric vectors of data from the healthy, intermediate and diseased class from Classifier 2, only needed in a comparison of two classifiers.

dat

a data frame of the following structure: The first column represents a factor with three levels, containing the true class membership of each measurement. The levels are ordered according to the convention of higher values for more severe disease status. The second column contains all measurements obtained from Classifier 1 (in the case of single marker assessment). In the case of comparison of two markers, column three contains the measurementss from the Classifier.

paired

logical; indicating whether data arose from a paired setting. If TRUE, each class must have equal sample size for both classifiers.

conf.level

confidence level of the interval. A numeric value between (0,1) yielding the significance level α=1-\code{conf.level}.

alternative

character string specifying the alternative hypothesis, must be one of "two.sided" (default), "greater" or "less". You can specify just the initial letter. For two sided test, notice H0: Z = (VUS_1-VUS_2) / (Var(VUS_1)+Var(VUS_2)-2Cov(VUS_1,VUS_2))^{0.5}.

Details

Based on the reference standard, this trinormal VUS test assesses the discriminatory power of classifiers by comparing the volumes under the ROC surfaces (VUS). It distinguishes between single classifier assessment, where a classifier is compared to the chance plane with VUS=1/6, and comparison between two classifiers. The latter case tests the equality between VUS_1 and VUS_2. The data can arise in a unpaired or paired setting. If paired is TRUE, a correlation is introduced which has to be taken into account. Therefore the sets of the two classifiers have to have classwise equal size. The data can be input as the data frame dat or as single vectors x1, y1, z1, ....

Value

A list of class "htest" containing the following components:

statistic

the value of the Z-statistic.

p.value

the p-value for the test.

conf.int

a confidence interval for the test.

estimate

a data frame containing the estimated VUS from Classifier 1 and Classifier 2 (if specified).

null.value

a character expressing the null hypothesis.

alternative

a character string describing the alternative hypothesis.

method

a character string indicating what type of trinormal VUS test was performed.

data.name

a character string giving the names of the data.

Summary

a data frame representing the number of NA's as well as the means and the standard deviations per class.

Sigma

the covariance matrix of the VUS.

References

Xiong, C., Van Belle, G. Miller J. P., Morris, J. C. (2006). Measuring and estimating diagnostic accuracy when there are three ordinal diagnostic groups. Statistics in Medicine, 25(7), 1251–1273.

Xiong, C., van Belle, G., Miller, J. P., Yan, Y., Gao, F., Yu, K., and Morris, J. C. (2007). A parametric comparison of diagnostic accuracy with three ordinal diagnostic groups. Biometrical Journal, 49(5), 682–693. doi: 10.1002/bimj.200610359.

See Also

trinROC.test, boot.test.

Examples

data(cancer)
data(krebs)

# investigate a single marker:
trinVUS.test(dat = cancer[,c(1,3)])
trinVUS.test(dat = krebs[,c(1,5)])

# result is equal to:
x1 <- with(cancer, cancer[trueClass=="healthy", 3])
y1 <- with(cancer, cancer[trueClass=="intermediate", 3])
z1 <- with(cancer, cancer[trueClass=="diseased", 3])
trinVUS.test(x1, y1, z1)

# comparison of marker 2 and 6:
trinVUS.test(dat = cancer[,c(1,3,5)], paired = TRUE)
trinVUS.test(dat = cancer[,c(1,3,5)], paired = FALSE)

# result is equal to:
x2 <- with(cancer, cancer[trueClass=="healthy", 5])
y2 <- with(cancer, cancer[trueClass=="intermediate", 5])
z2 <- with(cancer, cancer[trueClass=="diseased", 5])
trinVUS.test(x1, y1, z1, x2, y2, z2, paired = TRUE)

trinROC documentation built on Oct. 29, 2022, 1:12 a.m.