View source: R/TopKInference.R
| prepare.idata | R Documentation |
Function creates a data stream vector of zeros and ones (Idata) based on the preselected distance delta of the paired ordered lists. The obtained vector is further used as an input for compute.stream, a function that estimates the index position of information degradation.
prepare.idata(x, d)
x |
Data matrix or data frame, where the columns represent the lists of objects ordered according those rankings obtained from two different assessments. |
d |
The maximal distance between two lists for a ranked object |
The data stream vector is created as follows: if diff(rank1, rank2) of an individual object is less or equal delta, then 1 is assigned; otherwise 0. The smaller the delta value, the stronger the assumption of concordance for the paired ranked lists. When delta=0, the condition returns 1 for an object if and only if its rankings in the two lists are identical (the two objects share the same row).
The result is an object of type Idata, which is a list containing the data stream vector of zeros and ones, and the information about the applied distance delta
Idata |
Data stream vector of zeros and ones |
delta |
The applied |
Eva Budinska <budinska@iba.muni.cz>, Michael G. Schimek <michael.schimek@medunigraz.at>
compute.stream
set.seed(4568) A <- sample(1:20, 20) B <- sample(1:20, 20) C <- sample(1:20, 20) mm <- data.frame(A, B, C, row.names=LETTERS[1:20]) prepare.idata(mm, d=10) # The breast cancer example data(breast) Idata1 = prepare.idata(breast[,c(1,3)], d=10) # or Idata2 = prepare.idata(breast[,c(1,2)], d=10) # compare to Idata2 = prepare.idata(breast, d=10)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.