% Generated by roxygen2: do not edit by hand
% Please edit documentation in R/matrixplot_compartment.R
\name{compartment_matrixplot}
\alias{compartment_matrixplot}
\title{Compartment score matrix plot}
\usage{
compartment_matrixplot(
  exp1,
  exp2 = NULL,
  CS_discovery = NULL,
  chrom,
  arm = "p",
  colour_lim = NULL,
  rasterise = FALSE,
  metric = c("contacts", "obsexp", "log2obsexp", "correlation"),
  colour_bar = FALSE,
  ...
)
}
\arguments{
\item{exp1}{A GENOVA \code{contacts} object.}

\item{exp2}{A GENOVA \code{contacts} object compatible with \code{exp1} 
(optional) or \code{NULL}. If not \code{NULL}, the \code{exp2} argument 
will be displayed alongside the \code{exp1} data.}

\item{CS_discovery}{A \code{CS_discovery} object, as created by the 
\code{\link[GENOVA]{compartment_score}} function. When \code{NULL}, the
compartment score will be calculated on the fly for this arm only.}

\item{chrom}{A \code{character} of length 1 with a chromosome name.}

\item{arm}{Either \code{"p"}, \code{"q"} or \code{"all"}, denoting the 
chromosome arm of which to display the data from. \code{"all"} displays
the whole chromosome.}

\item{colour_lim}{A \code{numeric} of length two giving the minimum and 
maximum values in contact values. Out of bounds values will be set to the
nearest limits.}

\item{rasterise}{Set to \code{TRUE} to use a bitmap raster instead of 
polygons.}

\item{metric}{One of the follow: \describe{
  \item{\code{"contacts"}}{Displays contacts.}
  \item{\code{"obsexp"}}{Displays observed over expected by distance.}
  \item{\code{"log2obsexp"}}{Displays the log 2 observed over expected by 
  distance.}
  \item{\code{"correlation"}}{Displays Pearson correlation for the observed
    over expected by distance.}
}}

\item{colour_bar}{A \code{logical} of length 1, indicating whether a
colour-bar legend should be drawn at the right.}

\item{...}{Arguments passed to the \code{\link[GENOVA]{compartment_score}}
function.}
}
\value{
No values are returned but a plot is outputted on the graphics 
  device.
}
\description{
Display a Hi-C matrix with compartment scores annotated in the margins.
}
\details{
The 'on-the-fly' calculation of the compartment score uses the 
  default settings. Therefore, if for example a different eigenvector is to
  be retrieved, please use the \code{compartment_score} function and provide
  the result as the \code{CS_discovery} argument in this function.
}
\section{Recommended resolution}{
 100kb-150kb.
}

\examples{
\dontrun{ 
compartment_matrixplot(
  WT_150kb, KO_150kb,
  chrom = "chr18", arm = "q",
  metric = "correlation"
)
}
}
\seealso{
The \code{\link[GENOVA]{compartment_score}} function for computation
  of compartment scores.

Other matrix plots: 
\code{\link{hic_matrixplot}()},
\code{\link{insulation_matrixplot}()},
\code{\link{pyramid}()},
\code{\link{trans_matrixplot}()}
}
\concept{matrix plots}
