plotMV: Plot of Mean-Variance dependence and various fits

View source: R/VarID_functions.R

plotMVR Documentation

Plot of Mean-Variance dependence and various fits

Description

This functions plots the dependence of the transcript count variance or, alternatively, the coefficient of variation (CV) on the mean in log2 space. The mean-variance dependence is plotted along with a loess-regression, a second order polynomial fit, and the background model of the local variability. The CV plot also highlights the local variability associated with cell-to-cell variability of total transcript counts, as calculated directly from the mean and variance of total transcript counts (turquoise) or from a local fit of a gamma distribution (orange).

Usage

plotMV(x, cv = FALSE, ret = FALSE, span = 0.75, degree = 2, ...)

Arguments

x

Transcript count matrix.

cv

Logical. If TRUE then the coefficient of variation is plotted instead of the variance. Default is FALSE.

ret

Logical. If TRUE then a second order polynomial fit is returned. Default is FALSE

span

Parameter for the local regression. See help(loess). Default value is 0.75.

degree

Parameter for the local regression. See help(loess). Default value is 2.

...

Additional arguments for plot.

Value

If ret=FALSE second order polynomial fit as returned by lm.


RaceID documentation built on Sept. 28, 2023, 5:06 p.m.