Description Usage Arguments Value Author(s) References See Also Examples
A function to compute the Z values when planning an experiment with a binary exposure and a binary confounder. You input the probabilities of 3-cells of the resulting multinomial distribution.
1 | f(x, y, z)
|
x |
Proportion of elements in cell 1 of a multinomial population with four cells. |
y |
Proportion of elements in cell 2 of a multinomial population with four cells. |
z |
Proportion of elements in cell 1 of a multinomial population with four cells. The z here is different from the Z which contains information on the effect of covariates and data imbalance on sample size. |
It returns a single real number (greater than or equal 2), representing Z.
Stephen Nyangoma
Nyangoma SO, Ferreira JA, Collins SI, Altman DG, Johnson PJ, and Billingham LJ: Sample size calculations for planning clinical proteomic profiling studies using mass spectrometry. (Working paper)
The function ZvaluesformultinomialPlots
1 2 3 4 5 6 7 8 9 10 11 | # for a 1:1:1:1 experiment
x=.25;y=.25;z=.25
# compute Z
Z=f(x,y,z)
Z
## The function is currently defined as
function (x,y,z) {
Z=(1-x-z)*(x+y)/(2*(((1-x-z)*(1-x-y)*(1-y-z))-(1-x-y-z)^2))
Z
}
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.