create_rooted_tree: Create rooted tree from a taxonomy matrix

Description Usage Arguments Value Author(s) See Also Examples

Description

Create rooted tree from a taxonomy matrix

Usage

1
create_rooted_tree(df, root_taxon)

Arguments

df

data frame contains taxonomy matrix used for creating tree

root_taxon

taxon used for rooting tree

Value

rooted tree based on root_taxon

Author(s)

Vinh Tran tran@bio.uni-frankfurt.de

See Also

taxa2dist for distance matrix generation from a taxonomy matrix, get_taxonomy_matrix for getting taxonomy matrix, pp_taxonomy_matrix for a demo taxonomy matrix data

Examples

1
2
3
4
5
6
7
data("pp_taxonomy_matrix", package = "phyloprofile")
# prepare matrix for calculating distances
distDf <- subset(pp_taxonomy_matrix, select = -c(ncbiID, fullName))
row.names(distDf) <- distDf$abbrName
distDf <- distDf[, -1]
# create taxonomy tree rooted by ncbi10090
create_rooted_tree(distDf, "ncbi10090")

trvinh/test documentation built on May 9, 2019, 2:26 a.m.