SimDesign1 {SMARTbayesR} | R Documentation |
Simulate a SMART with Design 1
Description
This function simulates a SMART with Design 1.
Usage
SimDesign1(
sample_size = 250,
response_prob = c(0.5, 0.5, 0.5, 0.8, 0.7, 0.5),
stage_one_trt_one_response_prob = 0.7,
stage_one_trt_two_response_prob = 0.4
)
Arguments
sample_size |
the total sample size |
response_prob |
a vector of probabilities of response for each of the 6 embedded treatment sequences. |
stage_one_trt_one_response_prob |
the probability of response to first stage-1 treatment. |
stage_one_trt_two_response_prob |
the probability of response to second stage-1 treatment. |
Value
a data frame with treatment response indicators for each stage of treatment, a1 and a2, end of stage-1 response indicator s, and final outcome y.
Examples
dat <- SimDesign1(sample_size=250,
response_prob = c(0.5,0.9,0.3,0.7,0.5,0.8),
stage_one_trt_one_response_prob = 0.7,
stage_one_trt_two_response_prob = 0.4)
[Package SMARTbayesR version 2.0.0 Index]