Learn R Programming

episensr (version 1.3.0)

multiple.bias: Extract adjusted 2-by-2 table from episensr object

Description

Extract the adjusted 2-by-2 table from an episensr function, so that it can be re-used into an other episensr function when performing multiple (combined) bias analysis. Allowed functions are: selection, misclassification, confounders, probsens, probsens.sel, and probsens.conf.

Usage

multiple.bias(
  x,
  bias_function = c("selection", "misclassification", "confounders", "probsens.sel",
    "probsens.conf", "probsens"),
  ...
)

Value

A list with the elements corresponding to the bias function called.

Arguments

x

An object of class 'episensr' or 'episensr.probsens'.

bias_function

Bias function to be called. Choices between 'selection', 'misclassification', 'confounders', 'probsens', 'probsens.sel', 'probsens.conf'.

...

Additional arguments passed on to methods.

Details

For probabilistic bias analyses, median of cells are passed to the next function as starting 2-by-2 table.

See Also

selection, misclassification, confounders, probsens, probsens.sel, probsens.conf

Examples

Run this code
dat <- matrix(c(118, 832, 103, 884),
dimnames = list(c("BC+", "BC-"), c("AD+", "AD-")), nrow = 2, byrow = TRUE)

dat %>%
misclassification(., type = "exposure", bias_parms = c(.56, .58, .99, .97)) %>%
multiple.bias(., bias_function = "selection", bias_parms = c(.73, .61, .82, .76))

Run the code above in your browser using DataLab