replace_missing_number: Replace missing numeric value with another number.

Description Usage Arguments Value

View source: R/replace_missing_number.R

Description

Given a tibble and a column, this function will find target values (by default NA) and replace them with another number (by default 0).

Usage

1
2
3
4
5
6
7
replace_missing_number(
  this_data,
  this_var,
  this_function = NA,
  replacement_targets = NA,
  replacement_value = 0
)

Arguments

this_data

The tibble in which the column exists

this_var

The column name (if not a quosure, it will be made into one)

this_function

A label for error/warning messages (by default it is the name of this function).

replacement_targets

The value to be replaced (default=NA)

replacement_value

The value to replace it with (default=0)

Value

The updated tibble


LisaHopcroft/CTutils documentation built on Oct. 7, 2021, 11:08 p.m.