SampleControl {simFrame}R Documentation

Create objects of class "SampleControl"

Description

Create objects of class "SampleControl".

Usage

SampleControl(...)

Arguments

... arguments passed to new("SampleControl", ...).

Value

An object of class "SampleControl".

Author(s)

Andreas Alfons, alfons@statistik.tuwien.ac.at

See Also

SampleControl

Examples

data(eusilc)

## simple random sampling
srsc <- SampleControl(size = 20)
draw(eusilc[, c("id", "eqIncome")], srsc)

## group sampling
gsc <- SampleControl(group = "hid", size = 10)
draw(eusilc[, c("hid", "id", "eqIncome")], gsc)

## stratified sampling
sts <- SampleControl(design = "region", 
    size = c(2, 5, 5, 3, 4, 5, 3, 5, 2))
draw(eusilc[, c("id", "region", "eqIncome")], sts)

[Package simFrame version 0.1.1 Index]