traits_to_mfg_df {algaeClassify}R Documentation

Assign morphofunctional groups to a dataframe of functional traits and higher taxonomy

Description

Assign morphofunctional groups to a dataframe of functional traits and higher taxonomy

Usage

traits_to_mfg_df(dframe, arg.names = c("flagella", "size", "colonial",
  "filament", "centric", "gelatinous", "aerotopes", "class", "order"))

Arguments

dframe

An R dataframe containing functional trait information and higher taxonomy

arg.names

Character string of column names corresponding to arguments for traits_to_mfg()

Value

A character vector containing morpho-functional group (MFG) designations

Examples

#create a two-row example dataframe of functional traits
func.dframe=data.frame(flag=1,size=c("large","small"),col=0,fil=0,cent=NA,gel=0,
                       aer=0,cl="Euglenophyceae",or="Euglenales",stringsAsFactors=FALSE)
                       
#check the dataframe                       
print(func.dframe)                        

#run the function to produce a two-element character vector
traits_to_mfg_df(func.dframe,c("flag","size","col","fil","cent","gel","aer","cl","or"))

[Package algaeClassify version 0.1.0 Index]