|
template<domain D> |
D uint32 | contingencyTable (D uint32[[1]] data, D bool[[1]] cases, D bool[[1]] controls, uint32[[2]] codeBook) |
|
template<domain D> |
D uint64 | contingencyTable (D uint64[[1]] data, D bool[[1]] cases, D bool[[1]] controls, uint64[[2]] codeBook) |
|
Create a contingency table.
- Note
- D - all protection domains
-
Supported types - uint32 / uint64
- Parameters
-
data | - input vector |
cases | - vector indicating which elements of data belong to cases |
controls | - vector indicating which elements of data belong to controls |
codeBook | - matrix used for coding the answer. The first row contains expected values of the input vector and the second row contains the classes that these values will be put into. The classes should be consecutive and begin from 1. |
- Returns
- returns a contingency table in the format
-
| Cases | Controls |
Option 1 | c1 | d1 |
Option 2 | c2 | d2 |
Option 3 | c3 | d3 |
… | … | … |
- Leakage
- None
◆ contingencyTable() [1/2]
D uint32 contingencyTable |
( |
D uint32[[1]] |
data, |
|
|
D bool[[1]] |
cases, |
|
|
D bool[[1]] |
controls, |
|
|
uint32[[2]] |
codeBook |
|
) |
| |
◆ contingencyTable() [2/2]
D uint64 contingencyTable |
( |
D uint64[[1]] |
data, |
|
|
D bool[[1]] |
cases, |
|
|
D bool[[1]] |
controls, |
|
|
uint64[[2]] |
codeBook |
|
) |
| |