tornado_aggregate: Tornado plot for aggregated discoveries

View source: R/tornado_aggregates.R

tornado_aggregateR Documentation

Tornado plot for aggregated discoveries

Description

Takes the bins parallel to the Hi-C diagonal through the anchor locations and perform k-means clustering on these.

Usage

tornado_aggregate(
  discovery,
  znorm = TRUE,
  K = NULL,
  sort = NULL,
  colour_lim = NULL,
  min_var_exp = 0.7,
  print = TRUE
)

Arguments

discovery

One of the following discovery objects:

  • An APA_discovery object

  • A CSCAn_discovery object

  • A PESCAn_discovery object

znorm

A logical of length one deciding whether to z-score normalize every feature within samples (TRUE) or not (FALSE).

K

An integer of length or NULL, setting the number of clusters that kmeans() is instructed to find. When set to NULL, a search for an appropriate K is conducted to explain a fraction of the variance controlled by the min_var_exp argument.

sort

An integer setting sample indices on which the row-ordering must be computed. When NULL, orders on the mean of all samples.

colour_lim

A numeric of length two setting the minimum and maximum values of the colour scale respectively.

min_var_exp

A numeric between 0-1 that controls how much variance the kmeans() result should explain before choosing a K. When the K argument is not NULL, this is ignored.

print

A logical whether to immediately render the plot.

Value

A list with two elements; first a plot and second a data.frame with cluster annotations per feature.

Examples

## Not run: 
apa <- APA(explist, bed)
tornado_aggregate(apa)

## End(Not run)

robinweide/GENOVA documentation built on March 14, 2024, 11:16 p.m.