| optcost | R Documentation |
Computes stratum sample sizes that minimize the total survey cost for a given target variance of a stratified estimator, optionally subject to one-sided upper bounds on the stratum sample sizes. Specifically, the function solves the following optimization problem:
Minimize
c(x_1,\ldots,x_H) = \sum_{h=1}^H c_h x_h
over \mathbb R_+^H, subject to
\sum_{h=1}^H \frac{A^2_h}{x_h} - A_0 = V,
x_h \leq M_h, \qquad h = 1,\ldots,H,
where A_0,\, A_h > 0,\, c_h > 0,\, M_h > 0,\, h = 1,\ldots,H,
and V > \sum_{h=1}^H \frac{A^2_h}{M_h} - A_0, are given numbers.
The upper-bound constraints x_h \leq M_h are optional. If they are not
imposed, it is only required that V > 0.
optcost(V, A, A0, M = NULL, unit_costs = 1)
V |
( |
A |
( |
A0 |
( |
M |
( |
unit_costs |
( |
The allocation is computed using the LRNA algorithm, described in \insertCiteWojciakLRNA;textualstratallo.
The solution is valid for stratified sampling designs in which the variance
V_{st} of the stratified estimator can be expressed as
V_{st} = \sum_{h=1}^H \frac{A^2_h}{x_h} - A_0,
where H is the number of strata, x_1,\ldots,x_H are the stratum
sample sizes, and A_0,\, A_h > 0 do not depend on x_h.
A numeric vector containing the optimal sample allocation for each stratum.
For the stratified \pi-estimator of the population total under
stratified simple random sampling without replacement design, the
parameters take the form
A_h = N_h S_h, \qquad h = 1,\ldots,H,
A_0 = \sum_{h=1}^H N_h S_h^2,
where N_h is the size of stratum h and S_h is the
standard deviation of the study variable in stratum h.
WojciakLRNAstratallo
rna(), opt().
A <- c(3000, 4000, 5000, 2000)
M <- c(100, 90, 70, 80)
x <- optcost(1017579, A = A, A0 = 579, M = M)
x
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.