makeGenSpp: Create genus/species column

View source: R/makeGenSpp.R

makeGenSppR Documentation

Create genus/species column

Description

Creates genus/species column, accounting for empty species labels (adds "spp.")

Usage

makeGenSpp(d, genCol, sppCol, newCol = genSpp)

Arguments

d

Data frame or tibble

genCol

Genus column

sppCol

Species column

newCol

New column name (default = genSpp)

Value

Data frame with new genSpp column

Examples

dat <- data.frame(gen=c('Apis','Bombus','Nomada'),spp=c('mellifera','nevadensis',NA))
makeGenSpp(dat,gen,spp)

samuelVJrobinson/SRtools documentation built on Nov. 11, 2024, 12:37 p.m.