if (FALSE) {
############
## Example with two subsamples
############
N = 100; # population size
X = cbind(runif(N),runif(N)); # auxiliary variables
n = 10; # size of initial sample
p = rep(n/N,N); # inclusion probabilities of initial sample
sizes = c(7,3); # sizes of the two subsamples
hlpm(p,X,sizes) # selection of samples using hierarchical local pivotal method
}
Run the code above in your browser using DataLab