Skip to contents

Builds a heatmap of non-missing counts by wave for selected items.

Usage

plot_coverage(
  data,
  wave_col = "year",
  ques_cols = NULL,
  ques_stem = NULL,
  show_labels = TRUE
)

Arguments

data

Data frame containing the survey items.

wave_col

Column with wave identifiers (e.g., year).

ques_cols

Optional character vector of question columns to include.

ques_stem

Optional vector of substrings/regex used to match columns.

show_labels

Logical; draw percentage labels on tiles.

Value

ggplot object.