Description Usage Arguments Value Author(s) See Also

That is one of the main functions. It creates a plot or a table for the sample size, type I error rate and power versus standard deviation. The sample size, type I error rate and power can be calculated for the design with a fixed sample size and / or with an internal pilot study. If desired, it may represent several timings for the internal pilot studies for comparison.

1 2 3 | ```
sample_pow(sd_ber = T, delta = 0, Delta, sd, test = 1, alpha = 0.05, beta = 0.2,
prop = c(0.5, 0.7), adj = F, rule = F, nbound = 500,
fix_sim = c("fix", "sim"), simu = 10000, create = "plot")
``` |

`sd_ber` |
Sequence of numbers. Interval of the actual standard deviation in the data. |

`delta` |
Number. Expectation difference of two samples. |

`Delta` |
Number. Relevant difference of expected values in the alternative hypothesis. |

`sd` |
Number. Assumed standard deviation of the data. |

`test` |
Number. What type of hypothesis test should be performed, one-sided (Superiority/ |

`alpha` |
Number. Desired alpha-level of the test. |

`beta` |
Number. Acceptable beta error of the test. |

`prop` |
Number/ vector of numbers. |

`adj` |
Logical. Should the one-sample variance, calculated in the internal pilot study, be adjusted? |

`rule` |
Logical. Should the sample size adjustment rule be applied by Wittes and Brittain? |

`nbound` |
Number. Upper limit of the sample size. |

`fix_sim` |
Which design should be applied and presented? |

`simu` |
Number. How many simulations should be performed? |

`create` |
"plot" if a plot is to be returned. |

It returns a plot.

Csilla van Lunteren

`fix_sample_pow`

`sim_sample_pow`

ggplot2

gridExtra

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.