rename.genes: Name or rename a list of gene trees or matrices

View source: R/rename.genes.R

rename.genesR Documentation

Name or rename a list of gene trees or matrices

Description

Name or rename a list of gene trees or gene matrices genes. For internal use mostly.

Usage

rename.genes(X, gene.names = NULL)

Arguments

X

A list of trees or matrices

gene.names

List of names to assign to the elements of X. Must be of the same length as length(X). If NULL (the default) the object are numbered 1,2,...,length(X).

Value

X with name assigned to each element.

Examples


data(carnivora)

# names before renaming
names(carnivora)

carnivora.renamed<-rename.genes(carnivora, gene.names=as.character(1:length(carnivora)))

# names after renaming
names(carnivora.renamed)

phylter documentation built on Aug. 24, 2023, 9:10 a.m.