Learn R Programming

metamisc (version 0.1.9)

oecalc: Calculate the total O:E ratio

Description

This function calculates (transformed versions of) the ratio of total number of observed versus expected events with the corresponding sampling variance.

Usage

oecalc(OE, OE.se, OE.cilb, OE.ciub, OE.cilv, citl, citl.se, N, O, E, Po, Po.se,
  Pe, data, slab, add = 1/2, g = NULL, level = 0.95, ...)

Arguments

OE

vector with the estimated ratio of total observed versus total expected events

OE.se

vector with the standard errors of the estimated O:E ratios

OE.cilb

vector to specify the lower limits of the confidence interval for OE.

OE.ciub

vector to specify the upper limits of the confidence interval for OE.

OE.cilv

vector to specify the levels of aformentioned confidence interval limits. (default: 0.95, which corresponds to the 95% confidence interval).

citl

vector with the estimated calibration-in-the-large statistics

citl.se

vector with the standard error of the calibration-in-the-large statistics

N

vector to specify the sample/group sizes.

O

vector to specify the total number of observed events.

E

vector to specify the total number of expected events

Po

vector to specify the (cumulative) observed event probabilities.

Po.se

vector with the standard errors of Po.

Pe

vector to specify the (cumulative) expected event probabilites (if specified, during time t.val)

data

optional data frame containing the variables given to the arguments above.

slab

optional vector with labels for the studies.

add

a non-negative number indicating the amount to add to zero counts. See `Details'

g

a quoted string that is the function to transform estimates of the total O:E ratio; see the details below.

level

level for confidence interval, default 0.95.

Additional arguments.

Examples

Run this code
# NOT RUN {
######### Validation of prediction models with a binary outcome #########
data(EuroSCORE)

# Calculate the total O:E ratio and its standard error
oecalc(O=n.events, E=e.events, N=n, data=EuroSCORE, slab=Study)

# Calculate the log of the total O:E ratio and its standard error
oecalc(O=n.events, E=e.events, N=n, data=EuroSCORE, slab=Study, g="log(OE)")

# }

Run the code above in your browser using DataLab