Entering edit mode
7.8 years ago
maude
•
0
Hi everyone!
I have a BED file that I'm trying to load on UCSC but I don't understand why it's not working. My BED file looks like this:
"chr1" 3694 3695 2.0683270951919
"chr1" 8907 8908 2.0683270951919
"chr1" 9923 9924 2.0683270951919
"chr1" 17898 17899 4.13665419038381
"chr1" 18070 18071 4.13665419038381
"chr1" 19726 19727 2.0683270951919
"chr1" 19848 19849 2.0683270951919
"chr1" 20479 20480 2.75776946025587
When I try to load it, I have this error message:
Error File 'Peaks_t2_ip110.bedgraph.bed' - Unrecognized format line 1 of file: "chr1" 3694 3695 2.0683270951919 (note: chrom names are case sensitive, e.g.: correct: 'chr1', incorrect: 'Chr1', incorrect: '1')
Does anybody could explain me what is wrong with my file? Thank you, Maude
Thanks!
Unfortunately it's still not working...
Please use
ADD COMMENT/ADD REPLY
when responding to existing posts to keep threads logically organized.How did you modify your file? With
sed
or with excel or some other editor?I modified my R script:
write.table(f,paste(path,file,".bed", sep=""), sep="\t", col.name = FALSE, row.names = FALSE, quote = FALSE)
Because when I tried directly on the terminal with
It removed only the quote on the left part (chr1')
Sorry about that. I have modified the command to remove all instances of the quote character.
sed 's/\"//g' your_file.bed > new.bed
.BTW: I was able to use the snippet you posted above with UCSC after removing the quotes.
Thanks a lot for your help. Unfortunately something is still wrong with my file
Do you think it could be because BED files on UCSC need necessary an Header?
While I was able to get your file snippet to open in UCSC (without a header) I am not sure what those numbers are in the fourth column and if they are needed.
PS. I'm not able to use the snippet I posted even after removing the quotes... so maybe my problem is not coming from my file but it's something else related to the website. I will try to figure it out. Thank you very much!
It has been fixed. In fact I'm working with C.elegans and chromosomes' name needs to be different (chr1 = chrI). Thank you!