CrossMap Error With BigWig Files
1
2
Entering edit mode
5.2 years ago
skasowitz ▴ 20

I am attempting to liftover coordinates of several files in BigWig format from mm10 to mm9 using CrossMap. Below is an example of the output I am receiving with any of my files.

 python ~/python-2.7.9/bin/CrossMap.py bigwig mm10ToMm9.over.chain.gz KO_merged.bw KO_mm9
    @ 2017-03-13 15:16:16: Read chain_file:  mm10ToMm9.over.chain.gz
    @ 2017-03-13 15:16:18: Liftover bigwig file: KO_merged.bw ==> KO_mm9.bgr
    @ 2017-03-13 15:16:18: Merging overlapped entries in bedGraph file ...
    @ 2017-03-13 15:16:18: Sorting bedGraph file:KO_mm9.bgr
    Traceback (most recent call last):
      File "/home/kasowitz/python-2.7.9/bin/CrossMap.py", line 1636, in <module>
        crossmap_wig_file(mapTree, in_file, out_file, sourceChromSizes, targetChromSizes, in_format = 'bigwig')
      File "/home/kasowitz/python-2.7.9/bin/CrossMap.py", line 1445, in crossmap_wig_file
        for (chr, start, end, score) in bgrMerge.merge(out_prefix + '.bgr'):
      File "/home/kasowitz/python-2.7.9/lib/python2.7/site-packages/cmmodule/bgrMerge.py", line 95, in merge
        (last_chr, last_start, last_end, last_score) = lines[-1].split()
    IndexError: list index out of range

The error looks like it is resulting from receiving an empty bgr file, but I am not sure whats happening to cause the liftover to fail before this step.

Thanks for any advice

CrossMap • 2.1k views
ADD COMMENT
1
Entering edit mode

Hello I was wondering if you managed to find out what the issue was, I am having the same problem Thanks a lot

ADD REPLY
1
Entering edit mode
3.0 years ago
1528277449 ▴ 10

I encountered same problem. I found the key is the chromosome names in my wig file are numbers only (1,2,3...), but are chr1, chr2... in xx.over.chain.gz. After I added "chr" in my wig files, this problem was solved.

ADD COMMENT
0
Entering edit mode

But how did you change your bigwig file? Isn't it an executable file?

ADD REPLY

Login before adding your answer.

Traffic: 1056 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6