zero_to_na: Change nondetect representation

View source: R/7_impute.R

zero_to_naR Documentation

Change nondetect representation

Description

Change nondetect representation

Usage

zero_to_na(x, verbose = FALSE)

nan_to_na(x, verbose = FALSE)

na_to_zero(x, verbose = FALSE)

inf_to_na(x, verbose = FALSE)

minusinf_to_na(x, verbose = FALSE)

na_to_string(x)

Arguments

x

matrix

verbose

logical(1)

Value

Updated matrix

Examples

matrix(c(0, 7), nrow=1)
matrix(c(0, 7), nrow=1)    %>% zero_to_na(verbose=TRUE)

matrix(c(NA, 7), nrow=1)
matrix(c(NA, 7), nrow=1)   %>% na_to_zero(verbose=TRUE)

matrix(c(NaN, 7), nrow=1)
matrix(c(NaN, 7), nrow=1)  %>% nan_to_na(verbose=TRUE)

matrix(c(Inf, 7), nrow=1)
matrix(c(Inf, 7), nrow=1)  %>% inf_to_na(verbose=TRUE)

matrix(c(-Inf, 7), nrow=1)
matrix(c(-Inf, 7), nrow=1) %>% minusinf_to_na(verbose=TRUE)

bhagwataditya/autonomics documentation built on Nov. 1, 2024, 5:47 a.m.