getCorrelations: Get correlation coefficinets and p-values between biological...

Description Usage Arguments Value Author(s) Examples

View source: R/getCorrelations.R

Description

Get correlations and p-values between biological replicates based on coverage signal for peak regions. The signals will be filtered by the background cutoff value before calculated correlations. This function also output a correlation plots using the corrplot.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
getCorrelations(
  se,
  chr = paste0("chr", seq_len(19)),
  ratioAssay = "ratio",
  window = 10000L,
  cutoff = 1,
  method = c("spearman", "pearson", "kendall"),
  file_name = "Correlation plots.pdf",
  ...
)

Arguments

se

A RangedSummarizedExperiment object. The output from log2se.

chr

A vector of character. Filter for seqnames. It should be the chromosome names to be kept.

ratioAssay

character(1). Column name of ratio for correlation calculation.

window

numeric(1) or integer(1). The window size for summary of the ratios.

cutoff

numeric(1). All the coverage signals lower than cutoff value in a given window will be filtered out.

method

character(1) indicating which correlation coefficient is to be computed. See cor.

file_name

A file name for output correlation plots

...

Parameters not used.

Value

A list of matrixes of correlation coefficients and p-values.

Author(s)

Jianhong Ou, Haibo Liu

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
data(triplicate.count)
se <- triplicate.count
se <- log2se(se, transformation = "log2CPMRatio",
             nucleolusCols = c("N18.subsampled.srt-2.bam",
             "N18.subsampled.srt-3.bam",
             "N18.subsampled.srt.bam"),
             genomeCols = c("G18.subsampled.srt-2.bam",
             "G18.subsampled.srt-3.bam",
             "G18.subsampled.srt.bam"))
getCorrelations(se, chr="chr18")

NADfinder documentation built on Nov. 8, 2020, 5:35 p.m.