Simon-Coetzee / motifBreakR

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

SNPs recognized as indels? #30

Open Magda-M opened 3 years ago

Magda-M commented 3 years ago

I noticed that columns in motifbreakR output for my SNPs provided in .bed files are different for motifbreakR v 1.14 and 2.4. The columns "alleleRef" and "alleleAlt" reported by v 1.14 are replaced by "altPos" and "alleleDiff" in 2.4. Since no description is provided for "altPos" and "alleleDiff" in the documentation I tried to figure out how they are calculated by analyzing the source code. I must admit that my R skills are poor but what I understood is that the "altPos" and "alleleDiff" columns are expected in output when indels are analyzed, while output for SNPs should contain "alleleRef" and "alleleAlt" columns. I would be grateful for your help in figuring out what happens here. The commands that I used were:

library(motifbreakR)  
library(BSgenome.Hsapiens.UCSC.hg38)  
library(MotifDb)

snps.mb.frombed <- snps.from.file(file = "in_files/test.txt", search.genome = BSgenome.Hsapiens.UCSC.hg38, format = "bed")
motifs <- query(MotifDb, andStrings=c("hocomocov11", "hsapiens"))
results_log <- motifbreakR(snpList = snps.mb.frombed, filterp = TRUE,
                       pwmList = motifs,
                       threshold = 1e-5,
                       method = "log",
                       bkg = c(A=0.25, C=0.25, G=0.25, T=0.25),
                       BPPARAM = BiocParallel::bpparam())

Please find also attached an example input bed file. test.txt