Skip to contents

Computes the share of respondents who select the top response on pairs of questions, optionally weighted.

Usage

measure_pairwise_support(
  data,
  ques_cols = NULL,
  ques_stem = NULL,
  weight_col = NULL,
  include_self = TRUE,
  treat_na = c("exclude", "oppose")
)

Arguments

data

Data frame containing the survey items.

ques_cols

Optional character vector of question columns to include.

ques_stem

Optional vector of substrings/regex used to match columns.

weight_col

Optional weight column; if missing, unweighted.

include_self

Logical; include question self-pairs on the diagonal.

treat_na

How to handle pairs of NA (exclude from percentages or treat as 'oppose')

Value

Tibble with pairwise support statistics.