grp_rm: Remove one or more *gt* tables from a 'gt_group' container...

View source: R/gt_group.R

grp_rmR Documentation

Remove one or more gt tables from a gt_group container object

Description

A gt_group object, created through use of the gt_group() function, can hold a multiple of gt tables. However, you might want to delete one or more gt_tbl objects table from that container. With grp_rm(), this is possible and safe to perform. What's returned is a gt_group object with the specified gt_tbl objects gone. The only thing you need to provide is the index value for the gt table within the gt_group object.

Usage

grp_rm(data, which)

Arguments

data

The gt table group object

⁠obj:<gt_group>⁠ // required

This is a gt_group container object. It is typically generated through use of gt_group() along with one or more gt_tbl objects, or, made by splitting a gt table with gt_split().

which

The table to remove from the group

⁠scalar<numeric|integer>⁠ // required

A single index value denoting which gt_tbl table should be removed from the gt_group object.

Value

An object of class gt_group.

Function ID

14-7

Function Introduced

v0.9.0 (Mar 31, 2023)

See Also

Other table group functions: grp_add(), grp_clone(), grp_options(), grp_pull(), grp_replace(), gt_group(), gt_split()


gt documentation built on Sept. 11, 2024, 5:15 p.m.