Convert a bed file to bigbed
Entering edit mode
10 days ago
LDT ▴ 210

I have downloaded a bed file from here for the Arabidopsis genome. I want to add the bed file as a custom track to my Arabidopsis genome, but I fail to convert the bed file to bigBed

You can see all my data in the following link.

When I use the following command

bedToBigBed -tab remap2022_sorted.bed arath.chrom.sizes

I take this error

Error line 874 of remap2022_sorted.bed: Expecting colour to consist of r,g,b values from 0 to 255. Got [153,209,10,43,5,32]

I have two questions:

  1. How can I create an r,g,b column in my bed file? Do you have any software to suggest?
  2. Is there software which converts bed files to bed12 files?

Any hint or direction is highly appreciated.

bed bed12 ucsc • 196 views
Entering edit mode
10 days ago

Your approach is correct, but there is an issue with your data.

The UCSC Genome Browser Help describes the bed format in detail and as you can see, some lines are malformed:

1   20850   21254   LFY:seedling    2   .   21025   21026   153,209,10,43,5,32
1   37934   38232   LFY:seedling    2   .   38080   38081   153,209,10,43,5,32


sed 's/,/\t/3' remap2022_sorted.bed > remap2022_sorted_split.bed

you can fix that as far as the colours are concerned. But the remainder 43,5,32 doesn't really make sense. (It could be a second colour code that was erroneously concatenated instead of substituted?)

According to the .as file, you should have tree more columns

int blockCount;    "Number of blocks"
int[blockCount] blockSizes; "Comma separated list of block sizes"
int[blockCount] chromStarts; "Start positions relative to chromStart"

and this data doesn't add up. So maybe it is the safest to drop it?

See more details about BigBed creation in this blogpost.


Login before adding your answer.

Traffic: 1266 users visited in the last hour
Help About
Access RSS

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

Powered by the version 2.3.6