No announcement yet.

loading bam file failure on IGV

  • Filter
  • Time
  • Show
Clear All
new posts

  • loading bam file failure on IGV

    Hi everyone,

    I tried to find the reason for a long time. But couldn't solve my problem.
    When loading my sorted bam file (with bai file in the same folder) on IGV, I could see nothing.
    My bam file data looks like this:

    I tried with a bam file downloaded online. It worked when I loaded the file on IGV.
    IL7_1788:1:61:1161:1010 99 MAL1 17 0 6H48M = 548 584 ACCCTGAACCCTAAACCCTAAACCCTGAACCCTAAACCCTGAACCCTG>>>>>>>>>>>>>>>>>>>>>>>><<<<<666626666666+66/662 AS:i:48 MS:i:11

    My DNA-seq data is very big. My bam file was produced by galaxy. I used the steps as follows in galaxy:
    map with bowtie
    filter sam
    sam to bam

    Any suggestions will be very appreciated!

  • #2
    Of course it is always hard to troubleshoot a problem, but the first thing that stands out to me as a difference between your good data and bad data are the reference names. In the good one you have 'MAL1' while in the bad one the name is 'Chr01'. If the names are not matching your reference then you will not see anything.

    Are you using the same reference in both cases? Or different ones? If so, what are the names inside the reference file itself?
    Last edited by westerman; 12-22-2011, 08:00 AM. Reason: Fixed some English.


    • #3
      Like westerman said, I think the problem might be the reference names. If this human data and you are using one of the pre-loaded human genomes on the IGV, then they have "chr1" and not "chr01" as the name of the chromosomes. So try changing the names of the reference in your file and see if that works.


      • #4
        I will echo the suggestion that this might be a chromosome name problem. What assembly were these aligned against?

        You can correct this by creating an "alias" file, as decribed here (at the bottom of the page)



        • #5
          I followed your suggestions. You're correct. It's a chromosome name problem. I'm so happy that I solved this problem finally. Thanks a lot.


          • #6
            Originally posted by ykingh View Post
            I followed your suggestions. You're correct. It's a chromosome name problem. I'm so happy that I solved this problem finally. Thanks a lot.
            By the way, this is, by far, the most common failure mode for IGV that I see. BAM file has one set of names for the chromosomes and the reference gff or gtf has another set. The result? No alignments are depicted. The solution? There are several, but all of them involve delving into the data files and either changing them or creating a table file and putting it in the right place for IGV to read it.

            At the very least I would propose that IGV should display a visible warning when a .bam file is loaded that contains no sequences mapped to any of the current reference sequences. Some along the lines of "the reference contains the sequences "chr1, chr2 ..." while the alignment file contains hits to the sequences "1, 2, ..." -- since none of these sequence names are the same, no alignments can be displayed."



            • #7
              I agree with the warning suggestion, I will do that. Its on our faq, and its not just an IGV issue (samtools, the GATK, UCSC, etc won't work either), but nevertheless a warning would be helpful. Fundamentally it means you are viewing your BAMs against a different fasta file than was used for the alignment step, so some caution is in order.

              -- Jim