hypothesis: Hypothesis wrapper

Description Usage Arguments Value Examples

View source: R/wrapper.R

Description

Wrapper function for the hypothesis in the trial.

Usage

1
2
3
4
5
6
7
8
hypothesis(
  delta = 0,
  futility_prob = 0.05,
  prob_accept_ha = 0.95,
  expected_success_prob = 0.9,
  alternative = "greater",
  .data = NULL
)

Arguments

delta

numeric. Threshold set for margin in null hypothesis. The default is set to 0.

futility_prob

numeric. Probability of futility. The default is 0.05.

prob_accept_ha

numeric. Posterior probability of accepting alternative hypothesis. The default is 0.95.

expected_success_prob

numeric. Probability of expected success.

alternative

character. The string specifying the alternative hypothesis, must be one of "greater" (default), "less" or "two.sided".

.data

NULL. This should not be changed by the user.

Value

A list with information of hypothesis testing (threshold, futility probability, probability of accepting the alternative hypothesis, and probability of expected success).

Examples

1
2
3
4
hypothesis(delta = 0, futility_prob = 0.05, prob_accept_ha = 0.95,
           expected_success_prob = 0.90, alternative = "greater")
hypothesis(delta = 0.2, futility_prob = 0.1, prob_accept_ha = 0.975,
           expected_success_prob = 0.80, alternative = "less")

thevaachandereng/bayesCT documentation built on July 25, 2020, 9:20 p.m.