rescale: Rescaling 'Ranges' object

Description Usage Arguments Value Author(s) See Also Examples

Description

rescale() rescales IRanges, GRanges, IRangesList and GRangesList by using minima and maxima derived from to and from.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
rescale(x, to = 1L, from = 1L)

## S4 method for signature 'IRanges'
rescale(x, to = 1L, from = 1L)

## S4 method for signature 'IRangesList'
rescale(x, to = 1L, from = 1L)

## S4 method for signature 'GRanges'
rescale(x, to = 1L, from = 1L)

## S4 method for signature 'GRangesList'
rescale(x, to = 1L, from = 1L)

Arguments

x

a IRanges, GRanges, IRangesList and GRangesList object

to, from

an IRanges object, a character vector coercible to IRanges or a integer vector parallel to x or with length = 1L.

Value

an object of the same type and dimensions as x

Author(s)

H. Pagès, F. Ernst

See Also

IRanges for details on character vectors coercible to IRanges.

Examples

1
2
3
4
5
x <- IRanges("5-10")
# widen the ranges
rescale(x, 100, 10)
# widen and shift
rescale(x, "31-60", "5-14")

EpiTxDb documentation built on March 26, 2021, 6 p.m.