if_all.: Create conditions on a selection of columns

if_all.R Documentation

Create conditions on a selection of columns

Description

Helpers to apply a filter across a selection of columns.

Usage

if_all.(.cols = everything(), .fns = NULL, ...)

Arguments

.cols

Selection of columns

.fns

Function to create filter conditions

...

Other arguments passed to the function

Examples

iris %>%
  filter(if_any(ends_with("Width"), ~ .x > 4))

iris %>%
  filter(if_all(ends_with("Width"), ~ .x > 2))

tidytable documentation built on Oct. 5, 2023, 5:07 p.m.