R/utils.R
get_region_cov.Rd
This utility function checks the user-provided region data.frame coverage
list (COVERAGE
) or computes a new one using brainflowprobes_cov.
This is used by four_panels and plot_coverage.
get_region_cov(
REGION,
COVERAGE = NULL,
VERBOSE = TRUE,
PD = brainflowprobes::pd
)
Either a single hg19 genomic sequence including the chromosome, start, end, and optionally strand separated by colons (e.g., 'chr20:10199446-10288068:+'), or a string of sequences. Must be character. Chromosome must be proceeded by 'chr'.
The output of brainflowprobes_cov for the input
REGION
. Defaults to NULL
but it can be pre-computed and saved
separately since this is the step that takes the longest to run. Also, this
is the only step that depends on rtracklayer's functionality for reading
BigWig files which does not run on Windows OS. So it could be run on a
non-Windows machine, saved, and then shared with Windows users.
A logical value indicating whether to print updates from the process of loading the data from the BigWig files.
A list of data.frames with the sumMapped
and files
columns. Defaults to the data included in this package.
If COVERAGE
is provided and all checks pass, then this function
returns COVERAGE
. Otherwise, it computes a new region coverage data.frame
list using brainflowprobes_cov.