Hello again,
There is a new work-around....
If you have bedGraph-format data with one score per genomic base, first
translate the bedGraph-format data into the most compact format, fixedStep.
(There is a program wigBedToStep in the /kent source tree, but it can also run
out of memory with large datasets). Use these few lines of perl to transform
the data (this applies only to data that are really fixedStep with step=1 and
span=1!):
<command that spits out bedGraph format>
| perl -pe '($chr, $start, undef, $score) = split; \
if ($chr ne $lastChr || $start != $lastStart+1) { \
print "fixedStep chrom=$chr start=$start step=1
span=1\n"; \
} \
$_ = "$score\n"; \
($lastChr, $lastStart) = ($chr, $start);' \
| wigToBigWig stdin ../../hg18/chrom.sizes $output.bw
So, if you are already not using fixedStep or variableStep, and your
coordinates meet the requirements for those, this is an alternate option you
can use right now.
FAQ w/ links for file format definitions: http://genome.ucsc.edu/FAQ/FAQformat
Hopefully this helps!
Jennifer Jackson
UCSC Genome Bioinformatics Group
Michael Hoffman wrote:
> Hi,
>
> I am trying to convert a bedGraph with 19 million rows to a bigWig. I
> have tried using wigToBigWig but I run out of RAM--I only have 15 GiB at
> my disposal. Is there an option to decrease the memory footprint of this
> utility?
>
> Many thanks,
> Michael Hoffman
>
> _______________________________________________
> Genome maillist - [email protected]
> https://lists.soe.ucsc.edu/mailman/listinfo/genome
>
_______________________________________________
Genome maillist - [email protected]
https://lists.soe.ucsc.edu/mailman/listinfo/genome