lt_hide: Hide columns

View source: R/tab.R

lt_hideR Documentation

Hide columns

Description

Drop columns from the rendered table without removing them from the data. The values still travel to the client in the spec, so they remain available to things that read the whole row, such as an interactive table's row detail (see the detail argument of lt_interactive()).

Usage

lt_hide(x, columns)

Arguments

x

An lt() object.

columns

Columns to select: a character vector of column names, integer positions, or a one-sided formula. A formula whose right-hand side references the pronoun . (the character vector of column names) is evaluated as a predicate, e.g. ~ endsWith(., "_time") selects all columns whose names end with ⁠_time⁠; otherwise the bare names on the right-hand side are used, e.g. ~ x + y.

Value

x with the hidden columns recorded.

Examples

lt(head(mtcars)) |> lt_hide(~ gear + carb)

lt documentation built on Oct. 17, 2026, 9:06 a.m.