Event: Event object

Description Usage Arguments Details References See Also Examples

Description

This function creates an object of class Event which can be added to an object of class DataModel.

Usage

1
Event(n.events, rando.ratio = NULL)

Arguments

n.events

defines a vector of number of events required.

rando.ratio

defines a vector of randomization ratios for each Sample object defined in the DataModel.

Details

This function can be used if the number of events needs to be fixed in an event-driven clinical trial. Either objects of class Event or SampleSize can be added to an object of class DataModel but not both.

References

http://gpaux.github.io/Mediana/

See Also

See Also DataModel.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# In this case study, the radomization ratio is 2:1 (Treatment:Placebo).

# Sample size parameters
event.count.total = c(390, 420)
randomization.ratio = c(1,2)

# Outcome parameters
median.time.placebo = 6
rate.placebo = log(2)/median.time.placebo
outcome.placebo = list(rate = rate.placebo)
median.time.treatment = 9
rate.treatment = log(2)/median.time.treatment
outcome.treatment = list(rate = rate.treatment)

# Dropout parameters
dropout.par = parameters(rate = 0.0115)

# Data model
data.model = DataModel() +
             OutcomeDist(outcome.dist = "ExpoDist") +
             Event(n.events = event.count.total, rando.ratio = randomization.ratio) +
             Design(enroll.period = 9,
                    study.duration = 21,
                    enroll.dist = "UniformDist",
                    dropout.dist = "ExpoDist",
                    dropout.dist.par = dropout.par) +
             Sample(id = "Placebo",
                    outcome.par = parameters(outcome.placebo)) +
             Sample(id = "Treatment",
                    outcome.par = parameters(outcome.treatment))

Mediana documentation built on May 8, 2019, 5:04 p.m.