Errors with sort-bed
1
0
Entering edit mode
10.0 years ago
catherine ▴ 250

I have bigwig file downloaded from GEO, and convert it to wig file using bigwigToWig (ftp://hgdownload.cse.ucsc.edu/apache/htdocs-rr/goldenPath/help/bigWig.html). And when I want to used sort-bed command in BEDOPS, it gives me error like this:

Non-numeric start coordinate. See line 1025 in GSM723005_H3K4me1-MEF.wig.

​But I checked manually and didn't find anything wrong in this file.

If I don't use sort-bed, but just use convert it to bed file by myself, then run BEDOPS, it returns me empty output file (although I think the file is already sorted).

Any idea what went wrong to my procedure?

Thank you very much!​

ChIP-Seq bedops • 2.8k views
ADD COMMENT
1
Entering edit mode

First, convert your wig file into bed. I would suggest to use wig2bed from bedops.

Then run sort-bed command on your converted file

ADD REPLY
0
Entering edit mode

yeah! i got it. tHANK YOU

ADD REPLY
0
Entering edit mode

are you trying to sort a WIG file with a sort-BED tool ??

ADD REPLY
0
Entering edit mode

yeah, Im trying to use sort-bed in BEDOPS, it is said the input could be wig file.

ADD REPLY
2
Entering edit mode

No, It does not say that.

It says that

The sort-bed utility requires one or more three-column BED file(s). Support for common headers (such as UCSC BED track headers) is included, although headers will be stripped from the output

ADD REPLY
0
Entering edit mode

Sorting arbitrarily large BED files is easy with sort-bed, which easily scales beyond available system memory, as needed. We also offer portable conversion scripts that transform data in common genomic formats (SAM/BAM, GFF/GTF, PSL, WIG, and VCF) to sorted BED data that are ready to use with core BEDOPS utilities.

http://bedops.readthedocs.org/en/latest/content/overview.html#bedops-tools-are-flexible

It's misleading

ADD REPLY
3
Entering edit mode
10.0 years ago

Sounds like you need to do something like:

$ wig2bed < GSM723005_H3K4me1-MEF.wig > GSM723005_H3K4me1-MEF.wig.bed

Like most BEDOPS apps, the wig2bed application exports sorted data by default, so you shouldn't need to pipe to sort-bed.

You would need to sort if you explicitly set wig2bed not to sort, as in the following:

$ wig2bed --do-not-sort < GSM723005_H3K4me1-MEF.wig | sort-bed - > GSM723005_H3K4me1-MEF.wig.bed

See wig2bed --help for a description and listing of options.

ADD COMMENT

Login before adding your answer.

Traffic: 2989 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

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

Powered by the version 2.3.6