% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plot-cladogram.R
\name{plot_cladogram}
\alias{plot_cladogram}
\title{plot cladogram of micobiomeMaker results}
\usage{
plot_cladogram(
  mm,
  color,
  only_marker = FALSE,
  branch_size = 0.2,
  alpha = 0.2,
  node_size_scale = 1,
  node_size_offset = 1,
  clade_label_level = 4,
  clade_label_font_size = 4,
  annotation_shape = 22,
  annotation_shape_size = 5,
  group_legend_param = list(),
  marker_legend_param = list()
)
}
\arguments{
\item{mm}{a \linkS4class{microbiomeMarker} object}

\item{color}{a color vector, used to highlight the clades of microbiome
biomarker. The values will be matched in order (usually alphabetical) with
the groups. If this is a named vector, then the colors will be matched
based on the names instead.}

\item{only_marker}{logical, whether show all the features or only
markers in the cladogram, default \code{FALSE}.}

\item{branch_size}{numeric, size of branch, default \code{0.2}}

\item{alpha}{alpha parameter for shading, default \code{0.2}}

\item{node_size_scale}{the parameter 'a' controlling node size:
\code{node_size=a*log(relative_abundance) + b}}

\item{node_size_offset}{the parameter 'b' controlling node size:
\code{node_size=a*log(relative_abundance) + b}}

\item{clade_label_level}{max level of taxa used to label the clade, other
level of taxa  will be shown on the side.}

\item{clade_label_font_size}{font size of the clade label, default 4.}

\item{annotation_shape}{shape used for annotation, default \code{22}}

\item{annotation_shape_size}{size used for annotation shape, default \code{5}}

\item{group_legend_param, marker_legend_param}{a list specifying
extra parameters of group legend and marker legend, such as \code{direction} (
the direction of the guide), \code{nrow} (the desired number of rows of
legends). See \code{\link[ggplot2:guide_legend]{ggplot2::guide_legend()}} for more details.}
}
\value{
a ggtree object
}
\description{
plot cladogram of micobiomeMaker results
}
\examples{
data(kostic_crc)
kostic_crc_small <- phyloseq::subset_taxa(
    kostic_crc,
    Phylum \%in\% c("Firmicutes")
)
mm_lefse <- run_lefse(
    kostic_crc_small,
    wilcoxon_cutoff = 0.01,
    group = "DIAGNOSIS",
    kw_cutoff = 0.01,
    multigrp_strat = TRUE,
    lda_cutoff = 4
)
plot_cladogram(mm_lefse, color = c("darkgreen", "red"))
}
\references{
This function is modified from \code{clada.anno} from microbiomeViz.
}
\seealso{
\code{\link[ggtree:ggtree]{ggtree::ggtree()}}
}
\author{
Chenhao Li, Guangchuang Yu, Chenghao Zhu, Yang Cao
}
