Reports the components, their membership columns and seeds, and how the sampled rows fall across the domains: the frame sets units belong to. A domain holding no rows is not shown, because absence from a sample is not evidence that the domain is empty in the population.
Usage
# S3 method for class 'frame_stack'
summary(object, ...)Arguments
- object
A
frame_stackproduced bystack_frames().- ...
Must be empty.
Details
The counts are rows, not distinct units. A unit listed in two frames and selected from both appears twice, once per frame that selected it, which is exactly the double count a composite weight has to resolve.
Examples
population <- data.frame(
person_id = 1:60,
in_landline = rep(c(TRUE, FALSE), times = c(40, 20)),
in_cell = rep(c(FALSE, TRUE), times = c(10, 50))
)
frames <- stack_frames(
landline = sampling_design() |>
draw(n = 10) |>
execute(population[population$in_landline, ], seed = 1),
cell = sampling_design() |>
draw(n = 12) |>
execute(population[population$in_cell, ], seed = 2),
membership = c(landline = "in_landline", cell = "in_cell"),
key = person_id
)
summary(frames)
#> ── Frame Stack Summary ─────────────────────────────────────────────────────────
#>
#> ℹ 2 frames | 22 rows | key person_id
#>
#> Frames
#> • landline: 10 rows | in_landline | seed 1
#> • cell: 12 rows | in_cell | seed 2
#>
#> Domains
#> • cell: 3 rows
#> • cell+landline: 17 rows
#> • landline: 2 rows
#>
#> ℹ A unit listed in two frames is counted once per frame that selected it.
#>