Learn R Programming

WCE (version 1.0.3)

checkWCE: Verify that the arguments passed to the WCE function are in correct format

Description

This function checks whether the arguments passed to the WCE function are in the correct format. If at least one argument is incorrectly specified, the function returns an error message specifying what needs to be fixed.

Usage

checkWCE(data, id, event, start, stop, expos)

Value

checkWCE returns a message on the screen indicating whether the arguments are correctly specified or not.

Arguments

data

A data frame in the long (interval) format with one line per unit of time.

id

The name of the variable in data that identifies subjects.

event

The name of the variable in data that identifies the events (must be 0 or 1).

start

The name of the variable in data that identifies the beginning of the interval.

stop

The name of the variable in data that identifies the end of the interval.

expos

The name of the variable in data that represents the exposure of interest.

Details

The arguments passed to checkWCE must be exactly those passed to WCE.

Examples

Run this code
checkWCE(drugdata, id = "Id", event = "Event",  start = "Start", stop = "Stop", expos = "dose")

Run the code above in your browser using DataLab