Reads on chromosomes not displayed

2,913 views
Skip to first unread message

Mary Davis

unread,
Nov 5, 2013, 2:43:35 PM11/5/13
to igv-...@googlegroups.com
I have used IGV several times in the past months. Today I tried to use it again for a different dataset and the reads don't display for the chromosomes, except for mitochondrial (which is the main interest of the project, but there are reads to other chromosomes as well). This is mouse data; previous was human and that worked fine. Today, with the human I get the same result--mitochondria reads are there but other chromosomes are not. I can view the mouse data in Partek's genome browser just fine (IGV is easier to move around in, and see multiple tracks). I get that even if I load a saved session.
 
When I loaded IGV this morning (from the website), the Java version needed to be updated, so I did that:
version "1.7.0_45", Runtime Environment build 1.7.0_45-b18 HotSpot 64-Bit server VM build 24.45-b08, mixed mode.
 
I have attached the log and prefs files.
 
Thanks much
 
Mary Davis
igv.log
prefs.properties

Jacob Silterra

unread,
Nov 5, 2013, 4:14:44 PM11/5/13
to igv-...@googlegroups.com
Hi Mary,

This type of issue is usually a chromosome name mismatch. If the chromosome names in the BAM file are different than those in the IGV genome annotations, they won't be displayed. You can create an alias file to get around this by following the instructions at http://www.broadinstitute.org/software/igv/LoadData.

You can find out what the chromosome names are in the BAM file using samtools:

samtools view -H <filename>

will show the header. If the above doesn't help you resolve the issue, can you send the header of the BAM?

Thanks,


--
 
---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+u...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.



--
Jacob Silterra
Software Engineer
Broad Institute

Mary Davis

unread,
Nov 6, 2013, 10:16:00 AM11/6/13
to igv-...@googlegroups.com
The chromosome names appear to be the same in the bam files as what is displayed in the top pulldown to select a chromosome to view.

Screenshots of the header for two bam files are pasted into the word document attached.

Thanks again!

Mary Davis


--
 
---
You received this message because you are subscribed to a topic in the Google Groups "igv-help" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/igv-help/70WzPYuMMVw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to igv-help+u...@googlegroups.com.
Chromosomes in bam files.docx

Jacob Silterra

unread,
Nov 6, 2013, 10:31:07 AM11/6/13
to igv-...@googlegroups.com
Hi Mary,

They do indeed look the same. Some other things which could be happening:

- IGV only shows data at a certain zoom level. If you zoom in you may be able to see reads. This level can be adjusted in the preferences.
- IGV filters does some filtering of alignments as well, this can be set in view -> preferences -> alignments. If none of the alignments pass filtering they wouldn't get shown.

Can you upload the file to ftp.broadinstitute.org/incoming? If you are sure there is data in a particular region, you can extract it with:
samtools view [filename] [region] > output.sam

e.g.

samtools view mybam.bam chr13:112721913-112726020 > output.sam

Thanks,
-Jacob

Mary Davis

unread,
Nov 6, 2013, 1:50:32 PM11/6/13
to igv-...@googlegroups.com
Hi Jacob,

Here are files from two samples. (They are different alignments of the same data, which came out differently, which is part of what I'm trying to figure out.)

Thanks again

Mary
output1.sam
outputM1.sam

Jacob Silterra

unread,
Nov 6, 2013, 3:38:25 PM11/6/13
to igv-...@googlegroups.com
HI Mary,

Can you send a screenshot of what you see when you load these files? When I load the files you sent they view as expected (screenshot attached).

Thanks,
Screen Shot 2013-11-06 at 15.32.53.png

Mary Davis

unread,
Nov 6, 2013, 5:18:57 PM11/6/13
to igv-...@googlegroups.com
I can see them both, when really zoomed in. I thought I had zoomed in enough yesterday and couldn't see alignments or coverage. I attached two screen shots of chr11; the one that shows alignments is the most zoomed out that still shows the alignments--one more zoom out click gets the view captured in chr11out, and there is nothing shown on the coverage track.

I thought when I used IGV earlier, I could see the coverage before I could see the alignments--the coverage was a way to get to the alignments much faster. Am I missing something (or just losing  my mind)?

Thanks for your help

Mary
chr11out.JPG
chr11.JPG

Jacob Silterra

unread,
Nov 7, 2013, 10:56:12 AM11/7/13
to igv-...@googlegroups.com
Hi Mary,

If you create a tdf file from your alignment files using IGVTools you can see the coverage at higher zoom levels. IGV doesn't load alignments until it's within the visibility threshold (which you can increase in the preferences) so it can't calculate coverage on-the-fly when zoomed out too far. A TDF consists of precalculated coverage data, which can be viewed at any zoom level. See http://www.broadinstitute.org/igv/igvtools, the relevant command is "count".

Thanks,
-Jacob

Anthony Colombo

unread,
Jun 4, 2014, 7:19:24 PM6/4/14
to igv-...@googlegroups.com
Hi Jacob, I am having the same issue.  I am able to upload the data as .bam file format with the corresponding sorted index file.
 
however, I can not view the alignemtn tracks  and have the same issue.
 
Additionally, I can not convert to TDF because my files are .bam.   Advice?

James Robinson

unread,
Jun 4, 2014, 8:33:04 PM6/4/14
to igv-help
Hi Anthony, please describe your problem in more detail.    Have you verified that the sequence names in the BAM file match those in the reference sequence of the genome you are using?   

Its true bam files cannot be converted to tdf,  however coverage tracks in tdf format can be computed from bams using igvtools.  This will give you an overview of where the alignments are in your bam file.

Jim



On Wed, Jun 4, 2014 at 7:19 PM, Anthony Colombo <anthonyc...@gmail.com> wrote:
Hi Jacob, I am having the same issue.  I am able to upload the data as .bam file format with the corresponding sorted index file.
 
however, I can not view the alignemtn tracks  and have the same issue. -- 

Anthony Colombo

unread,
Jun 5, 2014, 12:26:54 PM6/5/14
to igv-...@googlegroups.com
Hello, I will give more detail.  I am a new user.
 
So first, I have two files in my directory that are bam files output from tophat.  accepted_hits.bam.  and accepted_hits.bam.bai.
How I processed them, is I ran tophat to get the bam file.  THen ran samtool sort on the accepted_hits.bam to sort the file, then I ran samtools index  on the sorted accepted_hits.bam file to get the index .bai file.
 
Then  I put both with MATCHING names prefixes in the same directory and loaded them into the IGV software.  First I had the same problem as Mary and saw no chromosome information.  Then after reading this thread, I was able to run IGV tools using the option "counts" and got the .tdrf for counts only.
 
See attached for the output to screen.   This output shows the alignment information.
 
The coverage track is computed from the "counts" command and is in TDF format, yes I completed this.
 
From the attached, I am able to see the alignment information stacked over the exons, and I know that we aligned using HG19 ref genome, so yes, this is the correct alignment information. 
 
 
 
I have two questions
 
1) I was not able to run the "toTDRF" command on the .bam files because it is not in .sam format, I was able to run the "counts" command from the IGVtools software, is this the correct steps for pre-processing the .bam data? 
2)  Are there other steps I need to take to complete the pre-processing of the .bam files ?  or is this how the data should look and the pre-processing is now finalized?
 
Thank you very much for your response.
 
AC
IGV.jpg

James Robinson

unread,
Jun 5, 2014, 12:52:45 PM6/5/14
to igv-help
Hi,  I see both alignments and coverage in your screenshot, everything looks correct.   So what are you expecting to see that you don't?



--

---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+u...@googlegroups.com.

Anthony Colombo

unread,
Jun 5, 2014, 1:34:34 PM6/5/14
to igv-...@googlegroups.com
I am a new user, and and reading on this software so I am not sure what to expect, but if this looks normal, then I will assume the preprocessing is complete.
 thank you


--

---
You received this message because you are subscribed to a topic in the Google Groups "igv-help" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/igv-help/70WzPYuMMVw/unsubscribe.
To unsubscribe from this group and all its topics, send an email to igv-help+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/CACOP%2BpvwHFRKGMANPhV2Hkqh_yhvdPVozBqM9cQYGH47mEQa7Q%40mail.gmail.com.

Gonzalo Villarino

unread,
Oct 21, 2014, 8:49:36 AM10/21/14
to igv-...@googlegroups.com
Dear Jim and all IGV users:

I run tophat2 using the Arabidopsis TAIR 10 genome. I indexed the bam files using samtool ($samtools index TRT_R3.Q30L50_accepted_hits.
bam TRT_R3.Q30L50_accepted_hits.bai) and have in one folder the all my files (.bai and .bam files), and when I upload the .bam file to IGV i see no alignment. I am selecting from the scroll-down menu the Arabidopsis TAIR 10 genome.

I am pretty confused. Any thought why this is not working? I would share by attaching the files but i think they are to heavy.

Many thanks all.

Gonzalo

Jim Robinson

unread,
Oct 21, 2014, 9:13:13 AM10/21/14
to igv-...@googlegroups.com
The most likely cause is that the sequence names in the bam alignments and IGV genome do not match.   Check the header of your bam file and compare the sequence names to use in the IGV genome.   If that is the problem you can solve it with an alias file, as described here:  http://www.broadinstitute.org/software/igv/LoadData/#aliasfile.   Alternatively,  you can load the fasta you used for the alignments as a "genome" (Genomes > Load genome from file...),  but if you do this you will have to provide your own annotations.

Gonzalo Villarino

unread,
Oct 21, 2014, 10:18:16 AM10/21/14
to igv-...@googlegroups.com
Thanks for your reply. I did convert one sample (.bam to .sam  to check) and this is what i got (i am copying just a portion):

@HD     VN:1.0  SO:coordinate
@SQ     SN:1    LN:30427671
@SQ     SN:2    LN:19698289
@SQ     SN:3    LN:23459830
@SQ     SN:4    LN:18585056
@SQ     SN:5    LN:26975502
@PG     ID:TopHat       VN:2.0.11       CL:/usr/local/bin/tophat -p 20 -G genes.gtf -o 01_tophat2_CTR_R1.Q30.L50.fq genome CTR_R1.fq.Q30.L50.gz
SRR1524935.22700264     0       1       3631    50      101M    *       0       0       AAATTATTAGATATACCAAACCAGAGAAAACAAATACATAATCGGAGAAATACAGATTACAGAGAGCGAGAGAGATCGACGGCGAAGCTCTTTACCCGGAA   @CCFFFFFHHHHHJJJJJIJJJJJIJJIJJJJJJJIGIIJJJJJJJIIJJJEGIJJJJJJJJJIIJJGHFFFDDDEDDDDBDBDDBDDDDCDDDDDDDDDB   AS:i:0  XN:i:0  XM:i:0  XO:i:0  XG:i:0  NM:i:0  MD:Z:101        YT:Z:UU XS:A:+  NH:i:1


I honestly do not know what this mean. I need to somehow modify this to make it match to the IGV genome? It almost sounds easier to re-run tophat2 using the Ensembl annotation....

Thanks for your help again.
-G

Jim Robinson

unread,
Oct 21, 2014, 10:24:40 AM10/21/14
to igv-...@googlegroups.com
Hi G,

This means that the chromosome names in your bam file are named  "1, 2, 3, 4, 5"  etc.   The chromosome files in the fasta IGV used to define the genome are named "Chr1, Chr2, Chr3,  etc).    So they don't match, and IGV does not know where to place the alignments.

This is easily fixed with an alias file as described in the link I sent,   just make a 2 column file (tab delimited) like this

1    Chr1
2    Chr2

etc.  Name this file  "tair10_alias.tab" and save it in the folder "<user home>/igv/genomes.   Restart IGV and you should see your alignments.

I will also add this alias to our hosted tair10 genome file, but that might take a few days.

Jim


Jim Robinson

unread,
Oct 21, 2014, 10:28:52 AM10/21/14
to igv-...@googlegroups.com
Actually I did a little more digging and this might not be the problem.   These particular aliases are already defined in our tair10 genome file.  Are you loading a custom genome?

Jim

Gonzalo Villarino

unread,
Oct 21, 2014, 10:47:53 AM10/21/14
to igv-...@googlegroups.com
Thanks taking the time Jim. So no need to the "alias" file anymore?

I think I am loading an IGV genome. IGV -> Select from the upper left scroll-down menu the A.thaliana (TAIR 10). Should I be doing something else?
Best
G

Jim Robinson

unread,
Oct 21, 2014, 10:56:34 AM10/21/14
to igv-...@googlegroups.com
Hi, what you are doing should work. To investigate further I need to
examine a sample of your file. Could you extract a small portion of
your bam or sam file, and send it to igv-team (at) broadinstitute.org.
You can use samtools to extract some portion of the bam, or just use a
unix command to get the first 1,000 lines or so of the sam file, as in

wc -l 1000 yourSamFile.sam > sample.sam

If using sam zip it before emailing.

Best

Jim

Gonzalo Villarino

unread,
Oct 21, 2014, 11:57:34 AM10/21/14
to igv-...@googlegroups.com
Jim,

I just emailed what you requested. I got this automatic reply:

This is an automatic reply. If you contacted us to ask a question about IGV, report a bug, or suggest a new feature, please note that the IGV email support has been moved to a forum at:
http://groups.google.com/group/igv-help.
If you need to reach the IGV team directly for other reasons, we will respond as soon as we can.
Please note that the Broad Institute will be closed from Monday December 23, 2013 through
Wednesday January 1, 2014.


Thanks again fr looking into this.
Best
G

Jim Robinson

unread,
Oct 21, 2014, 12:55:09 PM10/21/14
to igv-...@googlegroups.com
HI,

Thanks for the sample file.  After converting to bam I indexed the file and zoomed into the region with alignments.  I see them displayed as expected.  Are you sure you are zooming in far enough to see alignments?  Could you attache a screenshot of what you see,  attached is what I see.

Jim

Screen Shot 2014-10-21 at 12.52.44 PM.png

Gonzalo Villarino

unread,
Oct 21, 2014, 3:13:15 PM10/21/14
to igv-...@googlegroups.com
Thanks. I am really puzzled now but glad to know it is working. Attached are some of screenshots zoomed in and zoomed out.
Any ideas what could be wrong?

-G
Screen Shot 2014-10-21 at 3.05.26 PM.png.gz
Screen Shot 2014-10-21 at 3.05.50 PM.png.gz
Screen Shot 2014-10-21 at 3.06.28 PM.png.gz
Screen Shot 2014-10-21 at 3.07.16 PM.png.gz

Gonzalo Villarino

unread,
Oct 21, 2014, 4:07:35 PM10/21/14
to igv-...@googlegroups.com

Hi actually removed/uninstalled the IGV software and reinstalled it again. Loaded the TAIR10, the BAM files and I still see no alignment. Maybe the BAM files got somehow corrupted? I emailed you a SAM file which you converted to BAM and that worked, it is a long shot but is the only reasoning i can come up with.

Thanks
G

James Robinson

unread,
Oct 21, 2014, 4:34:57 PM10/21/14
to igv-help
Hi,  well obviously you aren't going to see alignments on the zoomed out views.  For the others,  I have no way to know if you have any alignments there, you won't see them if they aren't there.  I suggest you compute coverage for the whole genome with igvtools, you can do it from the tools menu or on the command line.   Load that and it should show you where the alignments are.

Jim


--

---
You received this message because you are subscribed to the Google Groups "igv-help" group.
To unsubscribe from this group and stop receiving emails from it, send an email to igv-help+u...@googlegroups.com.

Gonzalo Villarino

unread,
Oct 22, 2014, 8:54:04 AM10/22/14
to igv-...@googlegroups.com

Hi,

I downloaded the files again and uploaded them to IGV and it works. I have no idea what happened but is working now.
G
Reply all
Reply to author
Forward
0 new messages