signal_track_correlation: Compute correlation between signal track data for two samples

View source: R/signal_track_correlation.R

signal_track_correlationR Documentation

Compute correlation between signal track data for two samples

Description

Returns correlation between ChIP-seq signal of two samples. Useful to check replicates or compare different samples.

Usage

signal_track_correlation(
  signal_data_A,
  signal_data_B,
  genome,
  method = "pearson"
)

Arguments

signal_data_A

Input signal track data as a GRanges object (see ?"GRanges-class" for more details). To load wiggle and bedGraph data run import_wiggle and import_bedGraph, respectively. No default.

signal_data_B

Second samples' signal track data in the same format as signal_data_A object. No default.

genome

Character object specifying the genome version; accepts one of the following options:

  1. "SK1Yue"

  2. "sacCer3"

  3. "SK1"

No default.

method

Character object specifying which correlation coefficient is to be computed. Will be the input to the method argument of function cor of the stats package. Accepts one of (can be abbreviated):

  1. "pearson"

  2. "kendall"

  3. "spearman"

Defaults to "pearson".

Value

A floating point value corresponding to the signal correlation.

Examples

## Not run: 
signal_track_correlation(WT, dot1, genome = "SK1Yue")

signal_track_correlation(WT_A, WT_B, genome = "sacCer3", method="spearman")

## End(Not run)

hochwagenlab/hwglabr2 documentation built on Nov. 12, 2022, 7:27 p.m.