DiffBind: Error in `.rowNamesDF<-`(x, value = value) : invalid 'row.names' length
0
1
Entering edit mode
5.7 years ago
msimmer92 ▴ 310

Some background:

I am doing the differential binding analysis of some human histone ChIP-seq samples (bowtie2 mapping to hg19, duplicate marking, MACS2 narrow peak calling, blacklisted regions filtering with bedtools intersect and Anshul Kundaje's BED file for hg19). The samples are H, Y and Z and I'm comparing Y vs H and Z vs H (H is the control group). First, I did all that for with version hg38 and everything went fine. For some purpose, I needed to redo everything using the hg19 version of the genome. At the DiffBind step, the same script that did not have any problems before had only one error when dealing with the Y vs H comparison:

DiffBind: Error in `.rowNamesDF<-`(x, value = value) : invalid 'row.names' length

at the point of my script that I was doing a volcano plot (here you have the code I was using):

sampleInfo<-cbind.data.frame(treatmentList$SampleID,treatmentList$Condition,Species,bamReads,inputList$ControlID,bamControl,Peaks,PeakCaller)
results=dba(sampleSheet=sampleInfo)
results=dba.count(results,minOverlap=1,score=countNorm)
results$contrasts=NULL
results=dba.contrast(results,results$masks$Y,results$masks$H,unique(Condition)[2],unique(Condition)[1],minMembers=min(c(table(Condition))),categories=DBA_CONDITION)  
results=dba.analyze(results, method=DBA_DESEQ2)
pdf(paste(diffBindDir,"volc_plot.pdf",sep = ""))
dba.plotVolcano(results)
dev.off()

(entry 2 in the Condition vector is Y and entry 1 is H). After the volcano plot code, there's MAplot code and this one was produced without any problems.

The concrete problem:

How can it be that that sample is giving me this error? Since DiffBind has so many stuff inside each of its objects, does someone have some hints of what can be wrong? Thank you !

Specs:

MacOS High Sierra v10.13.6, Rstudio Version 1.1.463, R version 3.5.2 (2018-12-20) -- "Eggshell Igloo", DiffBind version 2.10.0

R DiffBind ChIP-Seq • 9.5k views
ADD COMMENT
1
Entering edit mode

I am the package maintainer for DiffBind. If you send a copy of (or link to) the DBA object results I can troubleshoot it for you. My email is in the DiffBind documentation.

-Rory

ADD REPLY
0
Entering edit mode

That is very kind of you to offer, thank you very much! I just shared with you the object.

ADD REPLY
0
Entering edit mode

Figure out a solution to this by chance? Getting similar error.

ADD REPLY
0
Entering edit mode

not from my side. still same problem

ADD REPLY
0
Entering edit mode

Since DiffBind has so many stuff inside each of its objects, does someone have some hints of what can be wrong

You might simply change the package. Not saying that DiffBind is not good but I heard more than once that people find DiffBind heavy-loaded and by this error prone. csaw (which is essentially a wrapper around edgeR) is more simplistic and you can write a simple wrapper around the main functions. You also do not have to use the window-based strategy it suggests but rather feed any count matrix into the edgeR workflow. Volcano and MAplots can be generated with R base graphics easily, so there is no absolute need for DiffBind. Again, I am not saying it is not good, but I simply want to offer an alternative.

ADD REPLY
0
Entering edit mode

Dear Rory, was there some problem with the object I sent you? Shall I sent it again or change anything? (I continue encountering this error, and curiously it is always in diffbind comparisons where the difference is not that big... could it be that, when numbers are small, certain calculation is crashing?). Again, thank you very much for your time.

ADD REPLY
1
Entering edit mode

Hey, may I suggest cross-posting this at the BioC support forum referencing this thread. I think Rory (like most BioC developers/maintainers) is far more active over there and this one simply fell into oblivion.

ADD REPLY
0
Entering edit mode

Ok , thank you very much !

ADD REPLY

Login before adding your answer.

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