BRD: Background Reads Density

Description Usage Arguments Value See Also

View source: R/BRD_V3.R

Description

The BRD function searches for background candidates based on the provided read count matrix and uses these background candidates to estimate normalization factors.

Usage

1
2
3
BRD(cnt, controls, sampling = NULL, smobs = NULL, dither = NULL,
  zscore = NULL, bins = NULL, smoothing = NULL, bdt = NULL,
  ncl = NULL, mincs = NULL)

Arguments

cnt

matrix of read counts (rows = observations, columns = measurement conditions).

controls

count columns corresponding to control measurements (Input, IgG, etc.).

smobs

subtract a mean count value for each observation (default = TRUE, recommended).

dither

number of replicates of the count dithering performed by DitherCounts: 1 = single, 2 = duplicate, 3 = triplicate, etc. (default = 5).

zscore

transform read count projections into z-scores (default = TRUE, recommended).

bins

number of bins per principal component for density estimations (default = 500).

smoothing

number of consecutive bins for local average smoothing of estimated densities (default = 10).

bdt

numeric vector of length 2 defining background density thresholds both expressed as proportions between 0 and 1. bdt[1] specifies the global threshold used to discard observations with low density prior to clustering. bdt[2] determines the maximum density loss allowed when selecting core observations relatively to the local maximum density in each cluster, and thus defining the background candidates. By default the value of bdt is c(0.2, 0.05) meaning that, in terms of density percentiles, the bottom 20 percents will be filtered out before clustering and only the top 5 percents can be selected as background candidates among each cluster.

ncl

number of clusters (density modes) to be distinguished.

mincs

minimum size of cluster cores, as number of observations.

Value

BRD returns a list with the following elements:

parameters

call parameters of the function.

status

execution status.

nonzero

indices of initial observations with count > 0.

dred

dimensionality-reduced non-zero observations.

subsets

partition of non-zero observations into background candidate subsets.

populations

summary of the core population in each subset.

theta

fitted distribution parameters for each core population.

log2counts

dithered and log2 transformed counts.

normfactors

BRD normalization factors.

See Also

PlotBRD, BackgroundCandidates, ScalingFactors, NormalizeCountMatrix, ReadCountMatrix


benja0x40/Tightrope documentation built on May 24, 2019, 1:35 a.m.