% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/plotHotspots.R
\name{plotHotspots}
\alias{plotHotspots}
\alias{plotHotspots.blisa}
\title{Spatial hotspot map for one ligand-receptor pair}
\usage{
plotHotspots(x, ...)

\method{plotHotspots}{blisa}(
  x,
  index = 1,
  ligand = NULL,
  receptor = NULL,
  log_pval = TRUE,
  p_cutoff = NULL,
  ...
)
}
\arguments{
\item{x}{A \code{blisa} object.}

\item{...}{Additional arguments passed to the method.}

\item{index}{Integer. Row index into \code{LR_results} selecting the
ligand-receptor pair to visualise. Ignored when both \code{ligand} and
\code{receptor} are supplied. Default \code{1} (top-ranked pair).}

\item{ligand}{Character. Ligand gene symbol. When both \code{ligand} and
\code{receptor} are provided the matching LR pair is located automatically
and \code{index} is ignored. Must be supplied together with
\code{receptor}.}

\item{receptor}{Character. Receptor gene symbol. Must be supplied together
with \code{ligand}.}

\item{log_pval}{Logical. If \code{TRUE} (default), colour significant bins
by -log10(p-value). If \code{FALSE}, use 1 - p-value.}

\item{p_cutoff}{Numeric or \code{NULL}. When \code{NULL} (default), the
pre-computed hotspot bins stored in the \code{blisa} object are used,
reflecting the \code{p_cutoff} and High-High quadrant classification
applied during \code{\link{blisa}}. When a numeric value is supplied,
bins are re-defined on the fly as those with \code{all_pval <= p_cutoff}
and quadrant label \code{"High-High"} (from the stored
\code{all_quadrant}), giving an exact re-threshold consistent with the
original classification.}
}
\value{
A \code{ggplot} object.
}
\description{
Generic function. Plots each bin coloured by significance status: empty,
non-significant, or significant hotspot (continuous gradient of
-log10 p-value or 1 - p-value).
}
\section{Methods (by class)}{
\itemize{
\item \code{plotHotspots(blisa)}: Method for a \code{blisa} object.

}}
