edit_info: Function to edit info data frames.

edit_infoR Documentation

Function to edit info data frames.

Description

Auxiliar function for smoothly editing the info data frame

Usage

edit_info(info, taxa, column = NULL, edit = NULL, remove.rows = FALSE)

Arguments

info

An info data frame.

taxa

Character vector with the taxa to be edited or removed.

column

The name of the column to be edited for the specified taxa. NULL is only accepted if remove.rows is TRUE.

edit

Any allowed value for the column to be edited. NULL is only accepted if remove.rows is TRUE.

remove.rows

If TRUE, the specified taxa will be removed from the info data frame (default is FALSE).

Value

An edited info data frame

Author(s)

Ignacio Ramos-Gutierrez, Rafael Molina-Venegas, Herlander Lima

Examples


 catspecies <- c("Lynx_lynx", "Panthera_uncia",
"Panthera_onca", "Felis_catus", "Puma_concolor",
"Lynx_canadensis", "Panthera_tigris", "Panthera_leo",
"Felis_silvestris")

cats.info <- build_info(species=catspecies, tree= cats,
     find.ranks=TRUE, db="ncbi", mode="backbone")

cats.info <- edit_info(cats.info, taxa= "Puma_concolor",
column = "subfamily", edit = "Felinae")


iramosgutierrez/randtip documentation built on March 19, 2024, 6:35 p.m.