contrastiveCov: Contrastive Covariance Matrices

View source: R/contrastiveCov.R

contrastiveCovR Documentation

Contrastive Covariance Matrices

Description

Compute the list of contrastive covariance matrices.

Usage

contrastiveCov(
  target,
  background,
  contrasts,
  center,
  scale,
  scaled_matrix = FALSE
)

Arguments

target

The target (experimental) data set, in a standard format such as a data.frame or matrix.

background

The background data set, in a standard format such as a data.frame or matrix.

contrasts

A numeric vector of the contrastive parameters.

center

A logical indicating whether the target and background data sets should be centered to mean zero.

scale

A logical indicating whether the target and background data sets should be scaled to unit variance.

scaled_matrix

A logical indicating whether to output a ScaledMatrix object. The centering and scaling procedure is delayed until later, permitting more efficient matrix multiplication and row or column sums downstream. However, this comes at the at the cost of numerical precision. Defaults to FALSE.

Value

A list of contrastive covariance matrices. Each element has an associated contrastive parameter in the contrasts vector.


PhilBoileau/scPCA documentation built on Feb. 6, 2024, 3:33 p.m.