View source: R/Df2RJafrocDataset.R
| Df2RJafrocDataset | R Documentation | 
Converts ratings arrays, ROC or FROC, but not LROC, to an RJafroc dataset, thereby allowing the user to leverage the file I/O, plotting and analyses capabilities of RJafroc.
Df2RJafrocDataset(NL, LL, InputIsCountsTable = FALSE, ...)
NL | 
 Non-lesion localizations array (or FP array for ROC data).  | 
LL | 
 Lesion localizations array (or TP array for ROC data).  | 
InputIsCountsTable | 
 If   | 
... | 
 Other elements of RJafroc dataset that may, depending on the
context, need to be specified.   | 
The function "senses" the data type (ROC or FROC) from the the
absence or presence of perCase.
ROC data can be NL[1:K1] and LL[1:K2] or NL[1:I,1:J,1:K1]
and LL[1:I,1:J,1:K2].
FROC data can be NL[1:K1,1:maxNL] and LL[1:K2, 1:maxLL] or
NL[1:I,1:J,1:K1,1:maxNL] and  LL[1:I,1:J,1:K2,1:maxLL].
Here maxNL/maxLL = maximum numbers of NLs/LLs, per case, over entire
dataset. Equal weights are assigned to every lesion (FROC data).
Consecutive characters/integers starting with "1" are assigned to
IDs, modalityID and readerID.
A dataset with the structure described in
RJafroc-package.
## Input as ratings arrays
set.seed(1);NL <- rnorm(5);LL <- rnorm(7)*1.5 + 2
dataset <- Df2RJafrocDataset(NL, LL)
## Input as counts tables
K1t <- c(30, 19, 8, 2, 1)
K2t <- c(5,  6, 5, 12, 22)
dataset <- Df2RJafrocDataset(K1t, K2t, InputIsCountsTable = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.