getPsi | R Documentation |
Get point-wise values of psi (inverse of nu prime)
getPsi(nuPrime, conditionalPower)
nuPrime |
The function value to be inverted. |
conditionalPower |
The target conditional power |
The function \psi
is the inverse of:
\nu'(\alpha) = -2 \cdot(\Phi^{-1}(1-\alpha) + \Phi^{-1}(1-CP)) / \phi(\Phi^{-1}(1-\alpha))
.
If the conditional power CP
lies outside of the range 1-\Phi(2) \leq CP \leq \Phi(2)
, the calculation is slightly more complicated.
The argument conditionalPower
is either the fixed target conditional power or the value of the conditional power function at the corresponding first-stage p-value.
The value of alpha which corresponds to nuPrime and lies between 0 and conditionalPower
.
# Returns 0.05
getPsi(getNuPrime(alpha = 0.05, conditionalPower = 0.9), conditionalPower = 0.9)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.