Companion bar chart for community_sharing_pq()
Source: R/community_sharing_pq.R
community_sharing_barplot_pq.RdComputes the same pairwise metrics as community_sharing_pq() and displays
them as grouped bars. Useful for precise numerical comparison alongside the
network figure.
Usage
community_sharing_barplot_pq(
physeq,
fact,
metrics = default_sharing_metrics(),
facet_by = c("metric", "pair"),
show_na_modality = FALSE,
base_size = 12,
title = NULL
)Arguments
- physeq
A
phyloseqobject.- fact
Character. Name of a
sample_data(physeq)column. Must have 2 to 4 unique values.- metrics
Named list of metric definitions from
make_sharing_metric(). Default:default_sharing_metrics().- facet_by
Character. One of
"metric"(default: one panel per metric, x-axis = pair label) or"pair"(one panel per pair, x-axis = metric label). Bar fill colors come from each metric'scolorfield.- show_na_modality
Logical. Same meaning as in
community_sharing_pq(). DefaultFALSE.- base_size
Base font size. Default
12.- title
Plot title. Default
NULL.