View source: R/cap03-aas-guarda-chuva.R
| aas_tamanho_amostra | R Documentation |
Convenience "umbrella" function that accepts every input that might be
relevant to determine an AAS sample size (population variance or
standard deviation, expected proportion, population size, expected
losses) and automatically dispatches to aas_tamanho_media() or
aas_tamanho_proporcao() depending on parametro, silently ignoring
whichever inputs are not needed for the chosen calculation.
aas_tamanho_amostra(
parametro = c("media", "proporcao"),
N = NULL,
sigma2 = NULL,
sigma = NULL,
p = NULL,
d,
conf = 0.95,
perda = 0,
arredondar = c("cima", "proximo"),
...
)
parametro |
Either |
N |
Optional population size. |
sigma2 |
Population variance (used only when |
sigma |
Population standard deviation (alternative to |
p |
Expected proportion (used only when |
d |
Tolerable margin of error. |
conf |
Confidence level, default |
perda |
Optional expected non-response/loss rate in |
arredondar |
Either |
... |
Ignored. Any other variables from a broader problem statement (e.g. sample data, stratum information) may be passed here without causing an error. |
A sampling_result object, as produced by
aas_tamanho_media() or aas_tamanho_proporcao().
aas_tamanho_amostra(parametro = "media", sigma = 7, d = 2)
aas_tamanho_amostra(parametro = "proporcao", p = 0.6, d = 0.03, N = 5000)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.