Description Usage Arguments Details Value Author(s) References See Also Examples
Given a predicted ICC and k
measures per individual/group, this function will calculate the N
individuals/groups required to obtain a desired confidence interval w
(according to Bonett, 2002).
1 2 |
est.type |
character string of either |
w |
desired width of the confidence interval about the ICC estimate |
ICC |
expected intraclass correlation coefficient |
k |
number of measurements per individual or group |
x |
column name of |
y |
column name of |
data |
a |
alpha |
the alpha level to use when estimating the confidence interval |
More than one ICC
or k
may be given. In this case, the return value is a dataframe with rows representing the values of the specified ICCs and the columns yield the different k
values.
data.frame
indicating the N number of individuals or groups to use to estimate the given ICC with a desired confidence interval width. Rows represent different levels of ICC while columns indicate different levels of k
measurements per individual/group.
Matthew Wolak matthewwolak@gmail.com
D.G. Bonett. 2002. Statistics in Medicine, 21(9): 1331-1335.
M.E. Wolak, D.J. Fairbairn, Y.R. Paulsen. 2011. Methods in Ecology and Evolution.
1 2 3 4 5 6 7 8 9 10 11 12 13 | #Example 1
n1<-Nest("h", w=0.14, ICC=0.1, k=10)
n1
#Example 2
data(ChickWeight)
Nest("p", w=0.14, x=Chick, y=weight, data=ChickWeight)
ex2<-ICCest(Chick, weight, ChickWeight)
ex2$UpperCI-ex2$LowerCI #confidence interval width of pilot study
ex2
#Example 3
Nest("h", w=0.14, ICC=seq(0.05, 0.15, 0.05), k=seq(10,12,1))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.