shelters <- readRDS("data/mwi_dzaleka_shelters.rds")
nrow(shelters)
#> [1] 8592
head(shelters, 3)
#> shelter_id x y
#> 1 1 594071.4 8489201
#> 2 2 594102.4 8488733
#> 3 3 593801.4 848905423 Special populations and multiple frames
A national frame of EAs reaches most households, but some groups poorly or not at all. Refugees in camps, people in institutions and nomads are outside it, or inside it in numbers too small for a national sample to meet. Large farms and enterprises are in it, but a list of them is a better frame for some purposes. This chapter takes three ways of reaching such groups. A group can have a frame of its own, a stratum of its own inside the national frame, or a second frame that overlaps the first. A fourth situation, units reached through others, closes the chapter.
23.1 A frame of its own
Dzaleka refugee camp, in Malawi, holds about 50,000 people. Its EAs are in the census frame, but the IHS6 sampled the camp from a frame of its own, the shelters UNHCR digitized from building footprints, and analyzed it separately (National Statistical Office 2026). A shelter is not a household. Some hold several households and some none, so the plan takes the shelter as the listing unit and interviews every household of a selected shelter (Chapter 28).
The frame is one row per shelter, with its projected coordinates x and y in meters, the variables the next draw spreads the sample over.
A camp is crowded and uneven. Water points, markets and the newest arrivals occupy parts of it. A sample of shelters drawn at random can by chance bunch in one part. The local pivotal method, lpm2, selects shelters with equal probability and spreads them over the camp, so that neighboring shelters are rarely selected together (Grafström and Matei 2018).
camp_design <- sampling_design("Dzaleka camp") |>
draw(n = 384, method = "lpm2", spread = c(x, y))
camp_sample <- execute(camp_design, shelters, seed = 2032)library(sf)
ggplot() +
geom_sf(data = read_layer("mwi_dzaleka"), fill = "grey97", color = "grey60") +
geom_sf(data = st_as_sf(shelters, coords = c("x", "y"), crs = 32736),
color = "grey75", size = 0.2) +
geom_sf(data = st_as_sf(as.data.frame(camp_sample), coords = c("x", "y"),
crs = 32736),
color = map_blue, size = 0.9) +
theme_map()
23.2 Virtual survey
Spreading pays when the outcome varies over the camp. The virtual survey gives each shelter an outcome whose probability changes smoothly with its position, standing in for an outcome such as distance to a water point, and draws 500 samples of 384 shelters by simple random sampling and by the local pivotal method.
set.seed(21)
centered <- scale(shelters[c("x", "y")])
shelters$y_out <- rbinom(nrow(shelters), 1,
plogis(-0.5 + 3 * sin(2 * centered[, 1]) +
2 * cos(2 * centered[, 2])))
draws <- function(method) {
design <- if (method == "lpm2") {
draw(sampling_design(), n = 384, method = "lpm2", spread = c(x, y))
} else {
draw(sampling_design(), n = 384, method = "srswor")
}
execute(design, shelters, seed = 3, reps = 500) |>
as.data.frame() |>
summarise(estimate = mean(y_out), .by = .replicate)
}
camp_virtual <- bind_rows(srs = draws("srswor"), lpm2 = draws("lpm2"),
.id = "method") |>
summarise(truth = mean(shelters$y_out), mean = mean(estimate),
true_se = sd(estimate), .by = method)
camp_virtual |>
mutate(across(where(is.numeric), \(x) round(x, 4)))
#> method truth mean true_se
#> 1 srs 0.4713 0.4736 0.0252
#> 2 lpm2 0.4713 0.4722 0.0157Both methods are unbiased. The spread sample has a standard error 37% smaller. The gain comes from the variation between parts of the camp, which a random sample can catch unevenly and a spread sample cannot. The size of the gain depends on how strongly the outcome varies over the camp, which this illustration makes strong. An outcome that varies little between parts of the camp gains little. The gain needs no assumption about which part of the camp differs, only that neighbors resemble each other. The price is the variance estimate. The local pivotal method has no linearization formula, and its standard error comes from a local neighborhood estimator or replicate weights (?variance_estimation).
23.3 A stratum inside the national frame
Rwanda’s camps appear in its census as villages whose name says so, and the frame of this book keeps them. The table lists them with their EAs and households.
rwa_eas <- readRDS("data/rwa_eas.rds")
camp_villages <- rwa_eas |>
filter(grepl("[Cc]amp", village)) |>
summarise(eas = n(), households = sum(households),
.by = c(district, village))
camp_villages
#> district village eas households
#> 1 Bugesera Gashora refugee Camp 1 93
#> 2 Gatsibo Nyabiheke Refugee Camp 17 2176
#> 3 Gisagara Mugombwa Refugee Camp 16 2057
#> 4 Karongi Kiziba Refugee Camp 22 2810
#> 5 Kirehe Mahama Refugee Camp 65 9032
#> 6 Kirehe Mahama Refugee Camp A 24 3410
#> 7 Nyamagabe Kigeme Refugee Camp 10 2011The 7 camp villages hold 155 EAs and 21,589 households, 0.65% of the country.
Whether a national survey reaches them is a question of scope as much as of frame. The 2022 census enumerated the camps as institutional households, listed and counted separately from the private households (National Institute of Statistics of Rwanda 2023, 18). The LFS covers people in private households, excludes institutional populations, and calibrates its weights to population totals without them (National Institute of Statistics of Rwanda 2024, 6 and 17). Neither document says whether the camp EAs are in the LFS frame. The questionnaire asks each member’s nationality and residence status but has no question on refugee status or camp residence (National Institute of Statistics of Rwanda 2024, 37 to 38), so the data cannot show whether the camps were reached. A plan that wants the camps in scope says so in its design report and keeps their EAs in the frame.
If the master sample of Chapter 27 kept the camp EAs and selected them like any other EA, it would meet them rarely.
psus <- rwa_psus(camps = TRUE) |>
mutate(camp = grepl("[Cc]amp", village))
plan <- rwa_plan()
camps <- psus |>
left_join(mutate(plan, stratum, n = n / 4 * 13,
.keep = "none"), by = "stratum") |>
mutate(chance = n * households / sum(households), .by = stratum) |>
summarise(master_psus = sum(chance),
expected_camp_psus = sum(chance[camp]))
camps
#> master_psus expected_camp_psus
#> 1 1794 10.55499The master sample of 1794 PSUs is expected to hold about 11 camp PSUs over two years. That would be enough for the camps to count in the national figures, but far too few for an estimate about refugees. A survey that needs one makes the camp EAs a stratum of their own and gives it a sample sized for its own target, as Chapter 8 sized an LGA. The national weights then take the camp stratum at its share of the population, and the oversample costs the national estimate a weighting loss that Chapter 10 can measure.
23.4 Two frames that overlap
Agricultural surveys often have two frames. An area frame (segments of land or EAs) reaches every holding but finds the few large ones rarely. A list frame, the register of commercial farms, holds the large ones and misses the small. Selecting from both and counting each holding once needs a dual-frame estimator. A holding on the list is also in the area frame, and a sample from each can reach it twice.
stack_frames() records which frames each sampled unit belongs to. Every component carries the membership of every frame, since a holding selected from the area frame must say whether it is also on the list. The population below is synthetic, 600 holdings of which the 120 largest are on the list.
set.seed(4)
holdings <- tibble(holding_id = 1:600,
hectares = round(rlnorm(600, log(2), 1.1), 1)) |>
mutate(in_list = rank(-hectares, ties.method = "first") <= 120,
in_area = TRUE)
holdings |>
summarise(holdings = n(), smallest = min(hectares),
largest = max(hectares), hectares = sum(hectares),
.by = in_list)
#> # A tibble: 2 × 5
#> in_list holdings smallest largest hectares
#> <lgl> <int> <dbl> <dbl> <dbl>
#> 1 FALSE 480 0.1 4.9 849.
#> 2 TRUE 120 4.9 65.7 1202.
frames <- stack_frames(
area = sampling_design() |>
draw(n = 60) |>
execute(holdings, seed = 1),
list = sampling_design() |>
draw(n = 30) |>
execute(filter(holdings, in_list), seed = 2),
membership = c(area = "in_area", list = "in_list"),
key = holding_id
)
svytotal(~hectares, as_svydesign(frames))
#> total SE
#> hectares 1971.2 161.61
sum(holdings$hectares)
#> [1] 2051.5The first table shows the 120 listed holdings next to the 480 others, with their smallest and largest sizes and their total area. The list holds a fifth of the holdings and most of the land. as_svydesign() uses the multiplicity estimator by default. A holding on both frames contributes half its weight through each, one over the number of frames that contain it (Mecatti 2007). An explicit theta gives Hartley’s estimator, which splits the overlap in a fixed proportion between the frames (Hartley 1962). Both are unbiased, and they differ in precision.
The gain from the second frame shows in a repeated draw. The multiplicity estimator from 60 area holdings and 30 list holdings is compared with 90 holdings from the area frame alone.
estimate <- function(seed) {
set.seed(seed)
a <- holdings[sample(600, 60), ]
l <- filter(holdings, in_list)[sample(120, 30), ]
dual <- sum(600 / 60 * a$hectares / (1 + a$in_list)) +
sum(120 / 30 * l$hectares / 2)
area_only <- 600 / 90 * sum(holdings$hectares[sample(600, 90)])
c(dual = dual, area_only = area_only)
}
replicates <- t(sapply(1:2000, estimate))
rbind(mean = colMeans(replicates), true_se = apply(replicates, 2, sd)) |>
round()
#> dual area_only
#> mean 2060 2056
#> true_se 196 295Both estimators are unbiased for the 2,052 hectares. The dual frame has a much smaller standard error, because the list samples the large holdings, which carry most of the area and most of its variance, at a rate of one in four instead of one in ten.
23.5 Units reached through others
Sometimes the units of interest are not in any frame, but are linked to units that are. Children are reached through their mothers, establishments through their enterprises, persons through their dwellings. The generalized weight share method gives each target unit the sum of the weights of the sampled units linked to it, divided by the number of links its cluster has in the whole population (Lavallée 2007). share_weights() applies it to an executed sample, with a link table that must be a complete register of the links, since the denominator counts links in the population, not in the sample.
dwellings <- data.frame(dwelling_id = 1:200)
dwelling_sample <- sampling_design() |>
draw(n = 20) |>
execute(dwellings, seed = 1)
people <- data.frame(person_id = 1:400, dwelling_id = rep(1:200, each = 2))
people_sample <- share_weights(
dwelling_sample, targets = people,
links = mutate(people, dwelling_id, person_id, .keep = "none"),
by = c(dwelling_id = "dwelling_id"), to = c(person_id = "person_id"),
within = dwelling_id, multiplicity = complete_links())
people_sample |>
as.data.frame() |>
select(person_id, dwelling_id, .weight) |>
head(4)
#> person_id dwelling_id .weight
#> 1 13 7 10
#> 2 14 7 10
#> 3 27 14 10
#> 4 28 14 10
c(dwellings = sum(dwelling_sample$.weight),
people = sum(people_sample$.weight))
#> dwellings people
#> 200 400Each person of a sampled dwelling receives the dwelling’s weight of 10, since the dwelling is the only unit linked to them, and the weights add up to the 400 people of the population.
A shared weight is an estimation weight, not the inverse of an inclusion probability. samplyr records it as such and refuses the uses that need a design weight. The multiplicity estimator of two frames is the same method, with each unit linked to the frames that contain it (Lohr 2021).
23.6 How the other surveys reach special populations
The IHS samples Dzaleka from its own frame and reports it separately. Most DHS and MICS cover the household population and leave out institutions and camps, which their reports state in the description of the frame. Labor force surveys cover camps when they are in the census frame, as in Rwanda, without a separate estimate. Agricultural censuses and surveys combine list and area frames more than any other survey family.
23.7 What to record
Dzaleka camp is sampled from a frame of 8,592 shelters digitized from building footprints, separately from the national frame, whose camp EAs are excluded. The local pivotal method selects 384 shelters with equal probability on their coordinates, and every household of a selected shelter is interviewed. Camp estimates are published separately, with standard errors from replicate weights.
23.8 Exercises
- Draw the camp sample with
method = "scps"instead of"lpm2". Is it also spread over the camp? - In the dual-frame example, put the 60 largest holdings on the list instead of 120, and rerun the check. How does the standard error change?
- Make the Rwanda camp EAs a stratum with 24 PSUs a quarter. How many camp PSUs does the master sample of 13 panels then hold?
- Yes. Spatially correlated Poisson sampling also spreads the sample over
spread, with a random sample size around its target. - The standard error stays about the same, near 200 hectares. The list now samples its holdings at one in two, but the next 60 largest move to the area frame, where they are sampled at one in ten. The two effects offset, and both lists beat the area frame alone by about a third.
- A panel holds a quarter of a stratum’s quarterly PSUs, so the master holds \(24 / 4 \times 13 = 78\) camp PSUs. Each quarter interviews the 24 PSUs of its four active panels, 288 households at 12 per PSU.