% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plotBiomarkerNetwork.R
\name{plotBiomarkerNetwork}
\alias{plotBiomarkerNetwork}
\title{Cross-Omics Biomarker Correlation Heatmap}
\usage{
plotBiomarkerNetwork(
  result,
  mae,
  n_host = 20L,
  n_mb = 15L,
  host_assay = "voom",
  mb_assay = "CLR",
  cor_thresh = 0,
  low_colour = "#F44336",
  mid_colour = "white",
  high_colour = "#2196F3"
)
}
\arguments{
\item{result}{A \code{\link{MOBResult}} object from
\code{\link{MultiOmicsBridgeAnalysis}}.}

\item{mae}{A \code{MultiAssayExperiment} from \code{\link{matchSamples}},
used to compute correlations from assay data.}

\item{n_host}{An \code{integer(1)} number of top host genes to display.
Default: \code{20}.}

\item{n_mb}{An \code{integer(1)} number of top microbial taxa to
display. Default: \code{15}.}

\item{host_assay}{A \code{character(1)} assay name in host SE.
Default: \code{"voom"}.}

\item{mb_assay}{A \code{character(1)} assay name in microbiome SE.
Default: \code{"CLR"}.}

\item{cor_thresh}{A \code{numeric(1)} minimum absolute correlation to
display (cells below this threshold are shown in grey). Default:
\code{0}.}

\item{low_colour}{A \code{character(1)} colour for strong negative
correlations. Default: \code{"#F44336"}.}

\item{mid_colour}{A \code{character(1)} colour for zero correlation.
Default: \code{"white"}.}

\item{high_colour}{A \code{character(1)} colour for strong positive
correlations. Default: \code{"#2196F3"}.}
}
\value{
A \code{ggplot2} object.
}
\description{
Produces a clustered heatmap of Spearman correlations between the top
selected host genes and microbial taxa. Rows represent host genes,
columns represent microbial taxa, and cell colour encodes the Spearman
correlation value. Strong positive or negative correlations between a
host gene and a microbial taxon suggest a potential functional
host-microbe interaction.
}
\examples{
set.seed(42)
host_counts <- matrix(rpois(500 * 20, 100), nrow = 500, ncol = 20,
    dimnames = list(paste0("Gene", 1:500), paste0("S", 1:20)))
host_counts[1:20, 11:20] <- host_counts[1:20, 11:20] * 5L
mb_counts <- matrix(rpois(60 * 20, 40), nrow = 60, ncol = 20,
    dimnames = list(paste0("Taxon", 1:60), paste0("S", 1:20)))

host_se <- loadHostData(host_counts)
mb_se   <- loadMicrobiomeData(mb_counts)
mae     <- matchSamples(host_se, mb_se)
outcome <- rep(c("ctrl", "treat"), each = 10)
result  <- MultiOmicsBridgeAnalysis(mae, outcome,
                                     n_components = 2,
                                     n_features_host = 20,
                                     n_features_mb = 10,
                                     n_biomarkers = 15, cv_folds = 3)
plotBiomarkerNetwork(result, mae, n_host = 10, n_mb = 8)

}
\seealso{
\code{\link{MultiOmicsBridgeAnalysis}}, \code{\link{plotIntegration}}
}
