b4S2: Statistical power for a hyphotesis testing on a single...

Description Usage Arguments Details Value Author(s) References See Also Examples

Description

This function computes the power for a (right tail) test of variance

Usage

1
b4S2(N, n, S2, S20, K = 0, DEFF = 1, conf = 0.95, power = 0.8, plot = FALSE)

Arguments

N

The population size.

n

The sample size.

S2

The value of the first estimated proportion.

S20

The value of the null effect. Note that S2 must be strictly smaller than S2.

K

The excess kurtosis of the variable in the population.

DEFF

The design effect of the sample design. By default DEFF = 1, which corresponds to a simple random sampling design.

conf

The statistical confidence. By default conf = 0.95.

power

The statistical power. By default power = 0.80.

plot

Optionally plot the power achieved for an specific sample size.

Details

We note that the power is defined as:

1-Φ(Z_{1-α} - \frac{(D-P)}{√{\frac{DEFF}{n}(1-\frac{n}{N})(P (1-P))}})

Value

The power of the test.

Author(s)

Hugo Andres Gutierrez Rojas <hagutierrezro at gmail.com>

References

Gutierrez, H. A. (2009), Estrategias de muestreo: Diseno de encuestas y estimacion de parametros. Editorial Universidad Santo Tomas

See Also

ss4p

Examples

1
2
3
b4S2(N = 100000, n = 400, S2 = 120, S20 = 100, K = 0, DEFF = 1)
b4S2(N = 100000, n = 400, S2 = 120, S20 = 100, K = 2, DEFF = 1)
b4S2(N = 100000, n = 400, S2 = 120, S20 = 100, K = 2, DEFF = 2.5, plot = TRUE)

samplesize4surveys documentation built on Jan. 18, 2020, 1:11 a.m.