Trouble loading bed file into IGV viewer Version 2.3.68(97) 01/13/2016 04:53PM on Ubuntu 14 LTS

1,594 views
Skip to first unread message

Sean Brimer

unread,
Jan 22, 2016, 12:35:00 PM1/22/16
to igv-help
Hello all, 

I have written a python script that will make a fast and bed file from a genbank file so I can use it for mapping and then viewing in IGV, however for some reason when I load the bed file I get this error:

 Error loading /home/sbrimer/genomes/G_anatisUMN179.bed: Error parsing line at byte position: htsjdk.tribble.readers.LineIteratorImpl@694df5b3, for input source: /home/sbrimer/genomes/G_anatisUMN179.bed     

My bed file looks like this:

Track name="G_anatisUMN179" description="G_anatisUMN179 genes"
G_anatisUMN179_dna 0 2687335 UMN179_RS12665 +
G_anatisUMN179_dna 210 1068 UMN179_RS00010 +
G_anatisUMN179_dna 1167 1980 UMN179_RS00015 -
G_anatisUMN179_dna 1972 2215 UMN179_RS00020 -
G_anatisUMN179_dna 2285 2618 UMN179_RS00025 +
G_anatisUMN179_dna 2671 4069 UMN179_RS00030 +
G_anatisUMN179_dna 4188 5592 UMN179_RS00035 -
G_anatisUMN179_dna 5861 7073 UMN179_RS00040 +
G_anatisUMN179_dna 7241 8294 UMN179_RS00045 -
G_anatisUMN179_dna 8309 9716 UMN179_RS00050 -
G_anatisUMN179_dna 9768 10383 UMN179_RS00055 +
G_anatisUMN179_dna 10460 10676 UMN179_RS00060 -
G_anatisUMN179_dna 10647 11184 UMN179_RS00065 -
G_anatisUMN179_dna 11294 11600 UMN179_RS00070 -
G_anatisUMN179_dna 11885 12902 UMN179_RS00075 -
G_anatisUMN179_dna 13163 13976 UMN179_RS00080 -
G_anatisUMN179_dna 13975 15172 UMN179_RS00085 -
G_anatisUMN179_dna 15181 16606 UMN179_RS00090 -
G_anatisUMN179_dna 16616 17618 UMN179_RS00095

I have tried parsing the file in slowly to see where the error is and I does not like the header and will not parse it. I thought I had the header correct is there something I need to add or remove it get this to work. Also I tried to removing the header and then loading the file, which it does but does not display any of the information.  

I have attached the genbak ref, my python script (requires biopython), and the output bed file can anyone give me a direction to go in to help solve this problem?
G_anatisUMN179.gb
genbank_to_fasta_with_bed_convert.py
G_anatisUMN179.bed

Sean Brimer

unread,
Jan 23, 2016, 10:55:32 PM1/23/16
to igv-help
I figured out that this issue was that the script created a different chromosome id then the fasta file I was using. 

Jim Robinson

unread,
Jan 24, 2016, 12:00:26 AM1/24/16
to igv-...@googlegroups.com
Ahh, thanks for the update.   Still, that mistake should not have caused a parsing error, and the error message is unhelpful.  I'll see if anything can be done to improve that.
--

---
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.
To view this discussion on the web visit https://groups.google.com/d/msgid/igv-help/b8919d43-dbe9-4c8f-9fc0-6eaf6db147b4%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Sun Loo

unread,
Apr 4, 2023, 10:59:27 PM4/4/23
to igv-help
I am having trouble loading a bed file onto IGV. 

I have checked that my script is accurate. 
Could you pls help me with this?
Thank you!



        Error loading C:\Users\xxx\OneDrive\Desktop\again.bed.txt: Error parsing LineIteratorImpl(SynchronousLineReader) at the first record, for input source: C:\Users\xxx\OneDrive\Desktop\again.bed.txt     

igv-help

unread,
Apr 10, 2023, 4:25:36 PM4/10/23
to igv-help
Remove the .txt suffix from the file name. If it's a bed file, it should end with .bed.

igv-help

unread,
Apr 10, 2023, 7:17:10 PM4/10/23
to igv-help
Poster is correct, extension should be bed, however .bed.txt will work with IGV.  It might be problematic for other tools though.

I can't really help without seeing the file,  but the first record in the file is not parsing correctly as "bed".

Masse

unread,
May 29, 2024, 2:10:07 PMMay 29
to igv-help
Hello,

I have similar problem with opening a bed file onto a loaded genome. Chromosome names are the same and the file format is bed, but I still get the above error.

example of the bed file:
2L_chromosome exon 16651231 16651234 Mlc2 +
2L_chromosome intron 16651234 16651872 Mlc2 +
2L_chromosome exon 16651872 16652112 Mlc2 +
2L_chromosome intron 16652112 16652337 Mlc2 +
2L_chromosome exon 16652337 16652757 Mlc2 +
2L_chromosome TE 16650501 16650578 Mlc2 +
3_chromosome exon 3953242 3953322 Abl -
3_chromosome intron 3953323 3953394 Abl -
3_chromosome exon 3953395 3954044 Abl -
3_chromosome intron 3954045 3954413 Abl -
3_chromosome exon 3954414 3956087 Abl -
3_chromosome intron 3956088 3957230 Abl -


Capture.JPG

igv-help

unread,
May 29, 2024, 3:26:56 PMMay 29
to igv-help
Hi, that is not a valid bed file.  See the file formats page in our user documentation,  or https://genome.ucsc.edu/FAQ/FAQformat.html#format1,  for a description of bed format.   The column with values "exon", "intron", etc is the likely problem.
Reply all
Reply to author
Forward
0 new messages