gintervals.force_range: Limits intervals to chromosomal range

View source: R/intervals.R

gintervals.force_rangeR Documentation

Limits intervals to chromosomal range

Description

Limits intervals to chromosomal range.

Usage

gintervals.force_range(intervals = NULL, intervals.set.out = NULL)

Arguments

intervals

intervals

intervals.set.out

intervals set name where the function result is optionally outputted

Details

This function enforces the intervals to be within the chromosomal range [0, chrom length) by altering the intervals' boundaries. Intervals that lay entirely outside of the chromosomal range are eliminated. The new intervals are returned.

If 'intervals.set.out' is not 'NULL' the result is saved as an intervals set. Use this parameter if the result size exceeds the limits of the physical memory.

Value

If 'intervals.set.out' is 'NULL' a data frame representing the intervals.

See Also

gintervals, gintervals.2d, gintervals.canonic

Examples



gdb.init_examples()
intervs <- data.frame(
    chrom = "chr1",
    start = c(11000, -100, 10000, 10500),
    end = c(12000, 200, 13000000, 10600)
)
gintervals.force_range(intervs)


misha documentation built on Sept. 14, 2023, 5:08 p.m.