|
a |
|
b/man/EventData.Rd |
|
|
1 |
% Generated by roxygen2: do not edit by hand |
|
|
2 |
% Please edit documentation in R/eventData.R |
|
|
3 |
\name{EventData} |
|
|
4 |
\alias{EventData} |
|
|
5 |
\title{Constructor for event data object} |
|
|
6 |
\usage{ |
|
|
7 |
EventData(data, subject, rand.date, has.event, withdrawn, time, site = NULL, |
|
|
8 |
event.type = NULL, remove.0.time = FALSE, followup = Inf) |
|
|
9 |
} |
|
|
10 |
\arguments{ |
|
|
11 |
\item{data}{A data frame} |
|
|
12 |
|
|
|
13 |
\item{subject}{string, the column name of subject identifiers} |
|
|
14 |
|
|
|
15 |
\item{rand.date}{string, the column name of randomization dates} |
|
|
16 |
|
|
|
17 |
\item{has.event}{string, the column name of whether a subject had an event |
|
|
18 |
(1) or not (0)} |
|
|
19 |
|
|
|
20 |
\item{withdrawn}{string, the column name of whether a subject has withdrawn |
|
|
21 |
(1) or not (0)} |
|
|
22 |
|
|
|
23 |
\item{time}{Either a string, the column name of time each subject has been on the study |
|
|
24 |
or a list with elements with (some of) the following named elements. |
|
|
25 |
\code{last.date}, \code{event.date}, \code{prog.date}, \code{dth.date} and \code{withdrawn.date} |
|
|
26 |
In this case the package will attempt to derive the time column |
|
|
27 |
See the vignette and then eventPrediction:::AddTimeColumn for further details} |
|
|
28 |
|
|
|
29 |
\item{site}{optional column for subject site} |
|
|
30 |
|
|
|
31 |
\item{event.type}{optional column for the event type (e.g. unstable angina) if not included then `Had Event' will be used} |
|
|
32 |
|
|
|
33 |
\item{remove.0.time}{logical, if TRUE then all subjects with time = NA or 0 are removed from the |
|
|
34 |
data set and not included in the object. If FALSE then they are included in the simulation (but not in the model fitting)} |
|
|
35 |
|
|
|
36 |
\item{followup}{A numeric value for the fixed follow up period a subject |
|
|
37 |
is followed. This is in days. If there is no fixed followup period then |
|
|
38 |
Inf should be used} |
|
|
39 |
} |
|
|
40 |
\value{ |
|
|
41 |
An \code{EventData} object |
|
|
42 |
} |
|
|
43 |
\description{ |
|
|
44 |
All dates must be in one of the following formats: |
|
|
45 |
YYYY-MM-DD, DD/MM/YY or DD Month YYYY |
|
|
46 |
} |
|
|
47 |
|