form.table: Forming Basic Tables

Description Usage Arguments Details Value Author(s) Examples

Description

Forms the crude, stratified tables suitable for using in other functions of this package.

Usage

1
form.table(Y1A1L1, Y1A0L1, Y1A1L0, Y1A0L0, Y0A1L1, Y0A0L1, Y0A1L0, Y0A0L0)

Arguments

Y1A1L1

Frequency of subjects who are treated (A=1), exposed to confounder (L=1) and developed the outcome (Y=1).

Y1A0L1

Frequency of subjects who are not treated (A=0), but exposed to confounder (L=1) and developed the outcome (Y=1).

Y1A1L0

Frequency of subjects who are treated (A=1), unexposed to confounder (L=0) and developed the outcome (Y=1).

Y1A0L0

Frequency of subjects who are not treated (A=0), unexposed to confounder (L=0) and developed the outcome (Y=1).

Y0A1L1

Frequency of subjects who are treated (A=1), exposed to confounder (L=1) but did not developed the outcome (Y=0).

Y0A0L1

Frequency of subjects who are not treated (A=0), but exposed to confounder (L=1) and did not developed the outcome (Y=0).

Y0A1L0

Frequency of subjects who are treated (A=1), unexposed to confounder (L=0) and did not developed the outcome (Y=0).

Y0A0L0

Frequency of subjects who are untreated (A=0), unexposed to confounder (L=0) and did not developed the outcome (Y=0).

Details

Frequency of all possible subject combination is required to insert in this function. This function eventually generates tables suitable for using in all other functions in this package.

Value

data

List frequencies

crude.data

Combines all the frequencies in a 2x2 table of treatment vs. outcome

stratified.table

Crude table is stratified by condounder exposure

condounder.exposed.data

2x2 table only containing subjects exposed to confounder

condounder.unexposed.data

2x2 table only containing subjects unexposed to confounder

Author(s)

Ehsan Karim ehsan@alumni.ubc.ca

Examples

1
2
form.table.object <- form.table(Y1A1L1=150, Y1A0L1=45, Y1A1L0=20, Y1A0L0=5, Y0A1L1=300, Y0A0L1=10, Y0A1L0=40, Y0A0L0=55)
form.table.object

ehsanx/iptw documentation built on May 16, 2019, 1:21 a.m.