Learn R Programming

pvclass (version 1.4.1)

analyze.pvs: Analyze P-Values

Description

Graphical displays and quantitative analyses of a matrix of p-values.

Usage

analyze.pvs(pv, Y = NULL, alpha = 0.05, roc = TRUE, pvplot = TRUE, cex = 1)

Value

T

Table containing empirical conditional inclusion and/or pattern probabilities for each class \(b\). In case of \(L = 2\) or \(L=3\) classes, all patterns \(S\) are considered. In case of \(L > 3\), all inclusion probabilities and some special patters \(S\) are considered.

Arguments

pv

matrix with p-values, e.g. output of cvpvs or pvs.

Y

optional. Vector indicating the classes which the observations belong to.

alpha

test level, i.e. 1 - confidence level.

roc

logical. If TRUE and Y is not NULL, ROC curves are plotted.

pvplot

logical. If TRUE or Y is NULL, the p-values are displayed graphically.

cex

A numerical value giving the amount by which plotting text should be magnified relative to the default.

Details

Displays the p-values graphically, i.e. it plots for each p-value a rectangle. The area of this rectangle is proportional to the the p-value. The rectangle is drawn blue if the p-value is greater than alpha and red otherwise.
If Y is not NULL, i.e. the class memberships of the observations are known (e.g. cross-validated p-values), then additionally it plots the empirical ROC curves and prints some empirical conditional inclusion probabilities \(I(b,\theta)\) and/or pattern probabilities \(P(b,S)\). Precisely, \(I(b,\theta)\) is the proportion of training observations of class \(b\) whose p-value for class \(\theta\) is greater than \(\alpha\), while \(P(b,S)\) is the proportion of training observations of class \(b\) such that the \((1 - \alpha)\)-prediction region equals \(S\).

References

Zumbrunnen N. and Dümbgen L. (2017) pvclass: An R Package for p Values for Classification. Journal of Statistical Software 78(4), 1--19. doi:10.18637/jss.v078.i04

Dümbgen L., Igl B.-W. and Munk A. (2008) P-Values for Classification. Electronic Journal of Statistics 2, 468--493, available at tools:::Rd_expr_doi("10.1214/08-EJS245").

Zumbrunnen N. (2014) P-Values for Classification – Computational Aspects and Asymptotics. Ph.D. thesis, University of Bern, available at http://boris.unibe.ch/id/eprint/53585.

See Also

cvpvs, pvs

Examples

Run this code
X <- iris[c(1:49, 51:99, 101:149), 1:4]
Y <- iris[c(1:49, 51:99, 101:149), 5]
NewX <- iris[c(50, 100, 150), 1:4]

cv <- cvpvs(X,Y)
analyze.pvs(cv,Y)

pv <- pvs(NewX, X, Y, method = 'k', k = 10)
analyze.pvs(pv)

Run the code above in your browser using DataLab