Skip to contents

Replace a NA value

Usage

replace_na(x, na_value)

Arguments

x

A vector

na_nalue

A single value, that will replace NA values

Value

A numeric value

Examples


replace_na(c(2,2,NA,NA,NA),1)
#> [1] 2 2 1 1 1