a formula with only a right-hand side, possibly containing a term of the form pending(x) to inform the function of which subjects have incomplete randomization ("randomization pending"). The pending variable is ignored if a subject has an exclusion marked. A randomized variable is an optional logical vector specifying which subjects are considered to have been randomized. The presence of this variable causes consistency checking against exclusions. One or more cond variables provide binary/logical vectors used to define subsets of subjects for which denominators are used to compute additional fractions of exclusions that are reported in a detailed table. The arguments of the cond function are the name of the original variable (assumed to be provided as a regular variable in formula, a single character string giving the label for the condition, and the vector of essentially binary values that specify the condition.
data
input data frame
subset
subsetting criteria
na.action
function for handling NAs when creating analysis frame
ignoreExcl
a formula with only a right-hand side, specifying the names of exclusion variable names that are to be ignored when counting exclusions (screen failures)
ignoreRand
a formula with only a right-hand side, specifying the names of exclusion variable names that are to be ignored when counting randomized subjects marked as exclusions
plotExRemain
set to FALSE to suppress plotting a 2-panel dot plot showing the number of subjects excluded and the fraction of enrolled subjects remaining
autoother
set to TRUE to add another exclusion Unspecified that is set to TRUE for non-pending subjects that have no other exclusions
sort
set to FALSE to not sort variables by descending exclusion frequency
whenapp
a named character vector (with names equal to names of variables in formula). For each variable that is only assessed (i.e., is not NA) under certain conditions, add an element to this vector naming the condition
erdata
a data frame that is subsetted on the combination of id variables when randomized is present, to print auxiliary information about randomized subjects who have exclusion criteria
panel
panel string
subpanel
If calling exReport more than once (e.g., for different values of sort), specify subpanel to distinguish the multiple calls. In that case, -subpanel will be appended to panel when creating figure labels and cross-references.
head
character string. Specifies initial text in the figure caption, otherwise a default is used.
tail
a character string to add to end of automatic caption
apptail
a character string to add to end of automatic caption for appendix table with listing of subject IDs
h
height of 2-panel graph
w
width of 2-panel graph
hc
height of cumulative exclusion 1-panel graph
wc
width of this 1-panel graph
adjustwidth
used to allow wide detailed exclusion table to go into left margin in order to be centered on the physical page. The default is '-0.75in', which works well when using article document class with default page width. To use the geometry package in LaTeX with margin=.45in specify adjustwidth='+.90in'.
append
set to TRUE if adding to an existing sub-report
popts
a list of options to pass to graphing functions
app
set to FALSE to prevent writing appendix information
Details
With input being a series of essentially binary variables with positive indicating that a subject is excluded for a specific reason, orders the reasons so that the first excludes the highest number of subjects, the second excludes the highest number of remaining subjects, and so on. If a randomization status variable is present, actually randomized (properly or not) subjects are excluded from counts of exclusions. First draws a single vertical axis graph showing cumulative exclusions, then creates a 2-panel dot chart with the first panel showing that information, along with the marginal frequencies of exclusions and the second showing the number of subjects remaining in the study after the sequential exclusions. A pop-up table is created showing those quantities plus fractions. There is an option to not sort by descending exclusion frequencies but instead to use the original variable order. Assumes that any factor variable exclusions that have only one level and that level indicates a positive finding, that variable has a denominator equal to the overall number of subjects.