R/main.R
get_sample_size_presence.Rd
Calculates the minimum sample size required per cluster to
achieve a certain power for the case of a clustered prevalence survey where
the aim is to detect the presence of any deletions over all clusters (see
?get_power_presence()
). Assumes the same sample size per cluster.
get_sample_size_presence(
n_clust,
target_power = 0.8,
prevalence = 0.01,
ICC = 0.05,
N_max = 2000
)
the number of clusters.
the power we are aiming to achieve.
assumed true prevalence of pfhrp2/3 deletions as a proportion between 0 and 1.
assumed true intra-cluster correlation (ICC) between 0 and 1.
the maximum allowed sample size. Sample sizes are only explored up to this value, after which point an error is returned.
get_sample_size_presence(n_clust = 5, prevalence = 0.01, ICC = 0.1)
#> [1] 294