Simon-Coetzee / motifBreakR

A Package For Predicting The Disruptiveness Of Single Nucleotide Polymorphisms On Transcription Factor Binding Sites.
27 stars 12 forks source link

motifbreakR with custom motifs #40

Closed magnitov closed 2 years ago

magnitov commented 2 years ago

Hi,

I wonder how I can use motifbreakR with a custom set of motifs, instead of fixed MotifDB instance? Any advice on how to create my own MotifList class object to use for pwmList argument?

Best, Mikhail

Simon-Coetzee commented 2 years ago

Hi Mikhail,

Sorry it isn't straight forward to create these. Looking at the structure of the objects released with https://bioconductor.org/packages/release/bioc/html/MotifDb.html and reverse engineering them manually is the only way I've done it in the past.

Good luck,

Simon

magnitov commented 2 years ago

Hi Simon,

Thanks for your reply. Would you mind providing a toy example, since you say that you did it? It seems to me that this question appeared here several times and still lacks a clear answer. To be honest, MotifDb documentations does not give much entry points and clues how one could do it.

Best, Mikhail

Simon-Coetzee commented 2 years ago

This is how I did it for a dataset in 2015, I believe the structure of the object has changed some since then. You'll have to inspect it yourself - This code has not been tested recently, but perhaps the concepts still hold.

https://gist.github.com/Simon-Coetzee/afff0b0a9cb71cec4f3eac6684f5507e