how i get get same length of peaks by macs2
1
0
Entering edit mode
5.8 years ago
mikysyc2016 ▴ 120

Hi, I find after i run macs2, i will get different zise of each peak. if i want to get peaks' length is 200, what kind of command I can use? Thanks

ChIP-Seq MACS2 • 1.7k views
ADD COMMENT
0
Entering edit mode

an example of input is needed.

ADD REPLY
1
Entering edit mode
5.8 years ago
ATpoint 81k

I hope you understand that peak calling is a data-driven kind of analysis. You cannot dictate the length of peaks you get. Still a technical solution would be to merge all peaks, take the center position of each and extend it by 100bp in each direction:

cat *.narrowPeak | sort -k1,1 -k2,2n | bedtools merge -i - | bedtools slop -r -0.5 -l -0.5 -pct -g genomesizes.txt -i - | bedtools slop -i - -r 100 -l 100 -g genomesizes.txt > peaks_extendedFromSummit200bp.bed
ADD COMMENT

Login before adding your answer.

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