change_na_rm: Removing and/or changing NA values Function for changing...

Description Usage Arguments Value Examples

View source: R/change_na_rm.R

Description

Removing and/or changing NA values Function for changing blank or non-NA values in a given data frame into NA values if not yet changed to NA, then removing the NA values from the data frame in one function. This function is beneficial for data frames being used with the 'tidyverse' package, but can also be used in base R for missing values.

Usage

1
change_na_rm(ants, "None")

Arguments

data

A data frame containing missing, non-NA, or NA values.

characterName

The non-NA or missing value to be replaced by NA. if this argument is left blank, the function will only remove the NA values that are already present in the data frame.

Value

The new data frame with missing, non-NA, or NA values replaced (if applicable) and removed.

Examples

1
2
 change_na_rm(combined)
 change_na_rm(butterfly, "Plebejus icarioides")

kateparrish9887/R_package_Parrish documentation built on Dec. 21, 2021, 5:20 a.m.