setNaToZero: Replace numeric NAs with 0 - update by reference

View source: R/utils-numeric.R

setNaToZeroR Documentation

Replace numeric NAs with 0 - update by reference

Description

This function replaces NAs in numeric columns with 0.

Usage

setNaToZero(df, cols = NULL)

Arguments

cols

vector of column names for which the NA replacement should occur. Default is all numeric columns.

x

data.table, data.frame, or list

Value

x with desired NAs replaced with 0.


VEuPathDB/veupathUtils documentation built on Feb. 8, 2025, 12:29 p.m.