read_wig {plyranges} | R Documentation

## Read a WIG file

### Description

This is a lightweight wrapper to the import family of functions defined in rtracklayer.

### Usage

    read_wig(file, genome_info = NULL, overlap_ranges = NULL)

### Arguments

`file` | A path to a file or a connection.
`genome_info` | An optional character string or a Ranges object that contains information about the genome build. For example the USSC identifier "hg19" will add build information to the returned GRanges.
`overlap_ranges` | An optional Ranges object. Only the intervals in the file that overlap the Ranges will be returned.

### Value

A GRanges object

A GRanges object

### See Also

`rtracklayer::WIGFile()`

### Examples

    test_path <- system.file("tests", package = "rtracklayer")
    test_wig <- file.path(test_path, "step.wig")
    gr <- read_wig(test_wig)
    gr
    gr <- read_wig(test_wig, genome_info = "hg19")

[Package plyranges version 1.6.10 Index]