update_value: Update Value

Description Usage Arguments Value Examples

View source: R/miscutils.R

Description

set value to update only if update passes miss condition

Usage

1
update_value(value, update, miss = is.null)

Arguments

value

the current value of the variable being updated

update

the updated value to check

miss

the condition function for update ( default = is.null )

Value

update if miss condition not met, otherwise value

Examples

1
2
3
4
y<- 100
y<-update_value(y, 200)
y<-update_value(y, NULL)
y<-update_value(y, 'a', function(x) x=='a')

duncankmckinnon/OKdplyr documentation built on Nov. 30, 2020, 1:13 a.m.