na_conformer: Conform NA entries to "NA" entries

View source: R/rodent_species.R

na_conformerR Documentation

Conform NA entries to "NA" entries

Description

Given the species abbreviation Neotoma albigula (NA), when data are read in, there can be an NA when it should be an "NA". This function conforms the entries to be proper character values.

Usage

na_conformer(dfv, colname = "species")

Arguments

dfv

Either [1] a data.frame containing colname as a column with NAs that need to be conformed to "NA"s or [2] a vector with NAs that need to be conformed to "NA"s.

colname

character value of the column name in tab to conform the NAs to "NA"s.

Value

x with any NA in colname replaced with "NA".

Examples

 na_conformer(c("a", "b", NA, "c"))


portalr documentation built on Aug. 23, 2023, 5:09 p.m.