tab.1test | R Documentation |
Produces a contingency table of results from a single binary diagnostic test vs. the gold-standard results.
tab.1test(d, y, data = NULL, testname, ...)
d |
A numeric vector specifying the gold-standard results (1 = presence of disease, 0 = absence of disease). |
y |
A numeric vector specifying the results of the diagnostic test (1 = positive, 0 = negative). |
data |
An optional data frame, list or environment containing the required variables |
testname |
An optional character variable specifying the name of the diagnostic test, e.g. |
... |
Additional arguments (usually not required). |
Returns a list of class tab.1test
:
tab.1test |
A contingency table (matrix) of test results.
| ||||||||||||||||
testname |
The name of the diagnostic test. |
Objects of class tab.1test
are required as arguments for acc.1test
, a function to compute the accuracy of a binary diagnostic test.
tab.paired
,
acc.1test
,
acc.paired
.
data(Paired1) # Hypothetical study data
a <- tab.1test(d=d, y=y1, data=Paired1)
str(a)
a$tab.1test
a
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.