This is a test version of Biostars. For the public version, visit https://www.biostars.org.
How to add Unique Peak ID to a bed file created from MACS for HOMER analysis

Hi all,

I'm new with using MACS and HOMER.
I have created a bed file using MACS, and got 5 columns, for example:

chr1    770811  771252  MACS_peak_1 93.92
chr1    851512  851790  MACS_peak_2 57.31
chr1    920907  921486  MACS_peak_3 207.37
chr1    946784  946982  MACS_peak_4 73.24

Does anyone knows how can I create a column that contains the Unique Peak ID for HOMER analysis? Also, What is the difference between using findMotifs.pl and findMotifsGenome.pl ? besides the fact that the first uses Unique Peak ID and the second uses genomic positions?

Appreciate your help!

chip-seq homer macs

1 answer

The difference between findMotifs.pl and findMotifsGenome.pl is that the first works with gene names (or IDs) as input, and the second with genome coordinates. You have coordinates so you can use findMotifsGenome.pl.

For this you need a bed file, I think only the first 4 columns are needed (I am not sure though if the 5th is ignored automatically, or that you have to remove it yourself first). The unique peak ID is already in the 4th column.

Something like this will find the motifs of your peaks.

findMotifsGenome.pl File_peaks.txt ~/Reference/hg38/ensembl/Homo_sapiens.GRCh38.dna.primary_assembly.fa File_peaks -p 20

Thanks! I thought so, and needed clarification. Can I ask you about the -size argument? I'm doing ChipSeq analysis, what is the common size to use?

I think best is to try the default size of 200 first. There is also an option to put size given, which means the exact size in your bed file will be used.

Check the manual by only typing in the function name:

findMotifsGenome.pl

Log in to answer this question.