[BioC] read gz compressed wig files?

Steve Lianoglou mailinglist.honeypot at gmail.com
Thu Mar 31 21:04:01 CEST 2011


Hi,

On Mon, Mar 28, 2011 at 5:32 PM, Hamid Bolouri <hbolouri at gmail.com> wrote:
> hi; Is there a way to read gz compressed wiggle files (.wig.gz)
> without decompressing them first? I couldn't find anything online.
>
> Example files:
>
> http://hgdownload.cse.ucsc.edu/goldenPath/hg18/encodeDCC/wgEncodeRegMarkEnhH3k27ac/

Maybe the import.wig (or import.bw if you've got bigwig files).

That function take in a `con` (connection) object, perhaps you can
make a "connection" to your wig.gz file via `gzopen()` and pass the
result into the import.wig, ie:

R> import.wig(gzopen('/path/to/*.wig.gz'))

I actually haven't tried it, but I reckon it could work.

-steve

-- 
Steve Lianoglou
Graduate Student: Computational Systems Biology
 | Memorial Sloan-Kettering Cancer Center
 | Weill Medical College of Cornell University
Contact Info: http://cbio.mskcc.org/~lianos/contact



More information about the Bioconductor mailing list