pwrss.t.mean | R Documentation |
Calculates statistical power or minimum required sample size (only one can be NULL at a time) to test a mean against a constant.
Formulas are validated using http://powerandsamplesize.com/, and tables in PASS documentation.
pwrss.t.mean(mu, sd = 1, mu0 = 0, margin = 0, alpha = 0.05,
alternative = c("not equal","greater","less",
"equivalent","non-inferior","superior"),
n = NULL, power = NULL, verbose = TRUE)
pwrss.z.mean(mu, sd = 1, mu0 = 0, margin = 0, alpha = 0.05,
alternative = c("not equal","greater","less",
"equivalent","non-inferior","superior"),
n = NULL, power = NULL, verbose = TRUE)
mu |
expected mean |
sd |
expected standard devation |
mu0 |
constant to be compared (a mean) |
n |
sample size |
power |
statistical power |
alpha |
probability of type I error |
margin |
non-inferority, superiority, or equivalence margin (margin: boundry of |
alternative |
direction or type of the hypothesis test: "not equal", "greater", "less", "equivalent", "non-inferior", or "superior" |
verbose |
if |
parms |
list of parameters used in calculation |
test |
type of the statistical test (z or t test) |
ncp |
non-centrality parameter |
df |
degrees of freedom |
power |
statistical power |
n |
sample size |
Bulus, M., & Polat, C. (in press). pwrss R paketi ile istatistiksel guc analizi [Statistical power analysis with pwrss R package]. Ahi Evran Universitesi Kirsehir Egitim Fakultesi Dergisi. https://osf.io/ua5fc/download/
# Example: A researcher is expecting a score of 23
# on Beck depression inventory (BDI) which is
# 0.50 standard devation above the threshold value 20
# (assume standard deviation of BDI scores is 6).
# to find that a score of 23 is greater than the threshold 20
pwrss.t.mean(mu = 23, mu0 = 20, sd = 6,
alpha = 0.05, power = 0.80,
alternative = "greater")
# standardized formulation
pwrss.t.mean(mu = 0.50, mu0 = 0, sd = 1,
alpha = 0.05, power = 0.80,
alternative = "greater")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.