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

The function `strata.bh`

stratifies a population given a set of boundaries. It calculates the stratum sample sizes and the anticipated coefficient of variation or relative root mean squared error.

1 2 3 4 5 |

`x` |
A vector containing the values of the stratification variable |

`bh` |
A vector of the |

`n` |
A numeric: the target sample size. It has no default value. The argument |

`CV` |
A numeric: the target coefficient of variation or relative root mean squared error if |

`Ls` |
A numeric: the number of sampled strata (take-none and certain strata are not counted in |

`certain` |
A vector giving the position, in the vector |

`alloc` |
A list specifying the allocation scheme. The list must contain 3 numerics for the 3 exponents |

`takenone` |
A numeric: the number of take-none strata (0 or 1). The default is 0, i.e. no take-none stratum is included. |

`bias.penalty` |
A numeric between 0 and 1 giving the penalty for the bias in the anticipated mean squared error (MSE) of the survey estimator (see |

`takeall` |
A numeric: the number of take-all strata (one of {0, 1, ..., |

`takeall.adjust` |
A logical. If |

`rh` |
A vector giving the anticipated response rates in each of the |

`model` |
A character string identifying the model used to describe the discrepancy between the stratification variable |

`model.control` |
A list of model parameters (see |

`Nh ` |
A vector of length |

`nh ` |
A vector of length |

`n ` |
The total sample size ( |

`nhnonint ` |
A vector of length |

`certain.info ` |
A vector giving statistics for the certainty stratum (see |

`opti.nh ` |
The final value of the criteria to optimize (either the total sample size |

`opti.nhnonint ` |
The final value of the criteria to optimize (either the total sample size |

`meanh ` |
A vector of length |

`varh ` |
A vector of length |

`mean ` |
A numeric: the anticipated global mean value of |

`RMSE ` |
A numeric: the root mean squared error (or standard error if |

`RRMSE ` |
A numeric: the anticipated relative root mean squared error (or coefficient of variation if |

`relativebias ` |
A numeric: the anticipated relative bias of the estimator, i.e. ( |

`propbiasMSE ` |
A numeric: the proportion of the MSE attributable to the bias of the estimator, i.e. ( |

`stratumID` |
A factor, having the same length as the input |

`takeall ` |
The number of take-all strata in the final solution. Note: It is possible that |

`call ` |
The function call (object of class "call"). |

`date ` |
A character string that contains the system date and time when the function ended. |

`args ` |
A list of all the argument values input to the function or set by default. |

Sophie Baillargeon Sophie.Baillargeon@mat.ulaval.ca and

Louis-Paul Rivest Louis-Paul.Rivest@mat.ulaval.ca

Baillargeon, S. and Rivest L.-P. (2011). The construction of stratified designs in R with the package stratification. *Survey Methodology*, **37**(1), 53-65.

`print.strata`

, `plot.strata`

, `strata.cumrootf`

, `strata.geo`

, `strata.LH`

1 2 3 4 5 6 7 8 9 | ```
adjust <- strata.geo(x=USbanks, CV=0.01, Ls=4, alloc=c(0.35,0.35,0))
adjust
adjust$nhnonint
noadjust <- strata.bh(x=USbanks, bh=adjust$bh, CV=0.01, Ls=4,
alloc=c(0.35,0.35,0), takeall=0, takeall.adjust=FALSE)
noadjust
noadjust$nhnonint
# without the adjustment for a take-all stratum, n is smaller than
# with the adjustment, but the target CV is not reached.
``` |

```
Given arguments:
x = USbanks
CV = 0.01, Ls = 4
allocation: q1 = 0.35, q2 = 0.35, q3 = 0
model = none
Strata information:
| type rh | bh E(Y) Var(Y) Nh nh fh
stratum 1 | take-some 1 | 135.30 103.26 382.33 156 33 0.21
stratum 2 | take-some 1 | 261.51 178.28 1136.94 109 37 0.34
stratum 3 | take-some 1 | 505.47 371.86 5350.88 63 42 0.67
stratum 4 | take-all 1 | 978.00 744.10 23105.75 29 29 1.00
Total 357 141 0.39
Total sample size: 141
Anticipated population mean: 225.6246
Anticipated CV: 0.009869827
[1] 32.05732 36.55587 41.66591 29.00000
Given arguments:
x = USbanks
CV = 0.01, Ls = 4, takenone = 0, takeall = 0
allocation: q1 = 0.35, q2 = 0.35, q3 = 0
model = none
Strata information:
| type rh bh | E(Y) Var(Y) Nh nh fh
stratum 1 | take-some 1 135.30 | 103.26 382.33 156 29 0.19
stratum 2 | take-some 1 261.51 | 178.28 1136.94 109 34 0.31
stratum 3 | take-some 1 505.47 | 371.86 5350.88 63 38 0.60
stratum 4 | take-some 1 978.00 | 744.10 23105.75 29 29 1.00
Total 357 130 0.36
Total sample size: 130
Anticipated population mean: 225.6246
Anticipated CV: 0.01079707
Note: CV=RRMSE (Relative Root Mean Squared Error) because takenone=0.
[1] 28.98880 33.05675 37.67766 35.57166
```

Embedding an R snippet on your website

Add the following code to your website.

For more information on customizing the embed code, read Embedding Snippets.