get_initial_design | R Documentation |

The optimization method `minimize`

requires an initial
design for optimization.
The function `get_initial_design`

provides an initial guess based on a
fixed design that fulfills constraints on type I error rate and power.
Note that a situation-specific initial design may be much more efficient.

```
get_initial_design(
theta,
alpha,
beta,
type = c("two-stage", "group-sequential", "one-stage"),
dist = Normal(),
order = 7L,
...
)
```

`theta` |
the alternative effect size in the normal case, the rate difference under the alternative in the binomial case |

`alpha` |
maximal type I error rate |

`beta` |
maximale type II error rate |

`type` |
is a two-stage, group-sequential, or one-stage design requried? |

`dist` |
distribution of the test statistic |

`order` |
desired integration order |

`...` |
further optional arguments |

The distribution of the test statistic is specified by `dist`

.
The default assumes a two-armed z-test.

An object of class `TwoStageDesign`

.

```
init <- get_initial_design(
theta = 0.3,
alpha = 0.025,
beta = 0.2,
type = "two-stage",
dist = Normal(two_armed = FALSE),
order = 7L
)
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.