Skip to contents

Returns TRUE if the design was created (or passed through) rowwise(). Use this predicate in estimation functions to detect and handle (or disallow) rowwise mode.

Usage

is_rowwise(design)

Arguments

design

A survey_base object.

Value

A scalar logical.

See also

Other grouping: group_by, is_grouped(), rowwise

Examples

# create a survey object from the bundled NPORS dataset
d <- surveycore::as_survey(
  surveycore::pew_npors_2025,
  weights = weight,
  strata = stratum
)

# FALSE for a freshly-built design; TRUE after rowwise()
is_rowwise(d)
#> [1] FALSE
is_rowwise(rowwise(d))
#> [1] TRUE