% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/parsePhylotree.R
\name{createRootedTree}
\alias{createRootedTree}
\title{Create rooted tree from a taxonomy matrix}
\usage{
createRootedTree(df, rootTaxon = NULL)
}
\arguments{
\item{df}{data frame contains taxonomy matrix used for generating tree
(see distDf in example)}

\item{rootTaxon}{taxon used for rooting the taxonomy tree}
}
\value{
A rooted taxonomy tree as an object of class "phylo".
}
\description{
Create rooted tree from a taxonomy matrix
}
\examples{
data("ppTaxonomyMatrix", package = "PhyloProfile")
# prepare matrix for calculating distances
distDf <- subset(ppTaxonomyMatrix, select = -c(ncbiID, fullName))
row.names(distDf) <- distDf$abbrName
distDf <- distDf[, -1]
# create taxonomy tree rooted by ncbi10090
createRootedTree(distDf, "ncbi10090")
}
\seealso{
\code{\link{taxa2dist}} for distance matrix generation from a
taxonomy matrix, \code{\link{getTaxonomyMatrix}} for getting taxonomy
matrix, \code{\link{ppTaxonomyMatrix}} for a demo taxonomy matrix data
}
\author{
Vinh Tran {tran@bio.uni-frankfurt.de}
}
