bedtools merge with strandedness giving now output
1
1
Entering edit mode
7.0 years ago
gatesss ▴ 10

Hello, I have a bed file and need to merge with strand specificity, but I am not getting an output.. my command is:

bedtools merge -i input.bed -s > merged.bed

my bed file looks like :

chr1    65702    65714    +

chr1    71879    71891    -

chr1    97442    97454    -

chr1    97552    97564    -

chr1    125938    125950    +

chr1    134489    134501    -

chr1    165663    165675    -

chr1    173419    173431    +

chr1    176257    176269    +

chr1    176263    176275    +

bedtools merge strandedness • 3.7k views
ADD COMMENT
4
Entering edit mode
7.0 years ago
PoGibas 5.0k

Try this:

awk '{OFS="\t"; print $1,$2,$3,".",".",$4}' INPUT.bed | bedtools merge -i - -s

Bed format contains strand information in column 6.

ADD COMMENT
0
Entering edit mode

awesome! thank you :)

ADD REPLY

Login before adding your answer.

Traffic: 2035 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