row_numeric_function: Row Numeric Function

Description Usage Arguments Value Note

View source: R/row_max_min.R

Description

Apply the function f to a tibble x rowwise

Usage

1
2
3
4
5
6
7
8
row_numeric_function(
  x,
  ...,
  na_rm = TRUE,
  append_col = TRUE,
  new_col_name = NA,
  f
)

Arguments

x

a tibble

...

columns of the tibble to compute the rowwise maximum on, must be numeric

na_rm

if TRUE ignore NAs if FALSE dont ignore

append_col

if TRUE adds a column to the end of x with the maximum

new_col_name

column name of the maximum, only used if append_col = TRUE, if left as name x_row_max used as default column name

f

the function name as string e.g. "max" for row maxes

Value

a vector

Note

in theory you could use a whole bunch of functions for f, have only written tests for max and min


neilcuz/panenkar documentation built on June 19, 2021, 7:31 p.m.