ard_tabulate_rows: Row Tabulate ARD

View source: R/ard_tabulate_rows.R

ard_tabulate_rowsR Documentation

Row Tabulate ARD

Description

Tabulate the number of rows in a data frame.

Usage

ard_tabulate_rows(
  data,
  colname = "..row_count..",
  by = dplyr::group_vars(data),
  strata = NULL,
  fmt_fun = NULL
)

Arguments

data

(data.frame)
a data frame

colname

(string)
name of the column that will be returned along with the row tabulation.

by, strata

(tidy-select)
columns to use for grouping or stratifying the table output. Arguments are similar, but with an important distinction:

by: results are tabulated by all combinations of the columns specified, including unobserved combinations and unobserved factor levels.

strata: results are tabulated by all observed combinations of the columns specified.

Arguments may be used in conjunction with one another.

fmt_fun

(formula-list-selector)
a named list, a list of formulas, or a single formula where the list element is a named list of functions (or the RHS of a formula), e.g. ⁠list(mpg = list(mean = \(x) round(x, digits = 2) |> as.character()))⁠.

Value

an ARD data frame of class 'card'

Examples

ard_tabulate_rows(ADSL, by = TRTA)

cards documentation built on Aug. 21, 2026, 5:09 p.m.