Skip to contents

Errors in a cluster sample of \(M\) units per cluster have exchangeable covariance with intraclass correlation \(\rho\). The quadratic form of a regressor \(x\) is \((1-\rho)\sum x^2 + \rho\sum_c(\sum_j x_{cj})^2\) (Research.P13.Design.quad_form): a cluster-level regressor inflates the naive variance by \(1 + (M-1)\rho\) (cluster_level), a within-cluster-balanced regressor deflates it by \(1 - \rho\) (within_balanced), and non-negativity at a one-cluster indicator forces \(\rho \ge -1/(M-1)\) (icc_lower_bound).

Usage

morie_design_effect_direction(rho, M, x = NULL)

Arguments

rho

Intraclass correlation, in \([-1/(M-1), 1]\).

M

Units per cluster (at least 2).

x

Optional regressor matrix with one row per cluster and M columns; its quadratic form and variance ratio are returned.

Value

A list: deff_cluster_level (1 + (M - 1) * rho), deff_within_balanced (1 - rho), icc_floor and, with x, quad, naive (sum(x^2)) and ratio.

References

Lohr SL (2019). Sampling: Design and Analysis, 2nd ed., section 5.2. CRC.

Examples

morie_design_effect_direction(rho = 0.1, M = 20)
#> $deff_cluster_level
#> [1] 2.9
#> 
#> $deff_within_balanced
#> [1] 0.9
#> 
#> $icc_floor
#> [1] -0.05263158
#> 
#> attr(,"theorem")
#> [1] "Research.P13.Design.quad_form"
x <- matrix(c(1, 1, 1, -1, -1, -1), nrow = 2, byrow = TRUE)
morie_design_effect_direction(rho = 0.1, M = 3, x = x)
#> $deff_cluster_level
#> [1] 1.2
#> 
#> $deff_within_balanced
#> [1] 0.9
#> 
#> $icc_floor
#> [1] -0.5
#> 
#> $quad
#> [1] 7.2
#> 
#> $naive
#> [1] 6
#> 
#> $ratio
#> [1] 1.2
#> 
#> attr(,"theorem")
#> [1] "Research.P13.Design.quad_form"