Question about Diffbind counts
0
0
Entering edit mode
slrpatty • 0
@3f073f21
Last seen 21 months ago
United States

I am trying to compare two different conditions (with 2 replicates each) using Diffbind. For my Diffbind output, I'm getting 0 counts for one of the conditions and high counts for the other condition. This doesn't seem to match my normalized browser tracks. There's clearly a peak around the chromosome position, but Diffbind is calculating it as 0 counts. There's definitely still a change in peak intensity between the two conditions, but it doesn't seem like it's reduced to 0. I was wondering if I'm doing something wrong or if I'm not understanding how the counts are calculated?

DiffBind • 1.5k views
ADD COMMENT
0
Entering edit mode

Could you show us the script you are using for the DiffBind analysis?

ADD REPLY
0
Entering edit mode
samples <- read.csv("UDDF.csv")

tamoxifen <- dba(sampleSheet="UDDF.csv")

tamoxifen.counted <- dba.count(tamoxifen, summits=250, bUseSummarizeOverlaps=F, score=DBA_SCORE_NORMALIZED)
counts <- dba.peakset(tamoxifen.counted, bRetrieve=T)
TEST <- as.data.frame(counts)

#the counts from the normalization is making some genomic regions 0 when they don't appear to be 0
#the counts do not match my browser tracks which are also normalized based on read depth

dba.plotPCA(tamoxifen.counted, attributes=DBA_TISSUE, label=DBA_ID)

tamoxifen.contrast <- dba.contrast(tamoxifen.counted, contrast=c("Condition","UD","DF"), minMembers=2)

tamoxifen.analysed <- dba.analyze(tamoxifen.contrast, method=DBA_ALL_METHODS, bBlacklist=F, bGreylist=F)

dba.plotVenn(tamoxifen.analysed,contrast=1,method=DBA_ALL_METHODS)
dba.show(tamoxifen.analysed, bContrasts=T)

report_deseq <- dba.report(tamoxifen.analysed, method=DBA_DESEQ2, contrast=1, th=1, bCounts=T)
report_edger <- dba.report(tamoxifen.analysed, method=DBA_EDGER, contrast=1, th=1, bCounts=T)

report.deseq_2 <- as.data.frame(report_deseq)
report.edger_2 <- as.data.frame(report_edger)

#also getting 0 counts after running deseq or edger
ADD REPLY
0
Entering edit mode

I notice you are using bUseSummarizeOverlaps=FALSE. Do you have a particular reason for doing so? Do you get the same behavior when you use the default bUseSummarizeOverlaps=TRUE?

Also, can you try running it with summits=0 and see if you still are getting zero counts?

ADD REPLY
0
Entering edit mode

Hi Rory. I discovered that the culprit were my input files. I had another question though. When using summits=250, some of my peaks aren't 500 bp. Although most of them are 500 bp, some of them are an odd width. Is there a reason for that? Thanks!

ADD REPLY
0
Entering edit mode

Yes, this is possible.

In the first step, the summits are computed for all merged peaks in the consensus peakset. Next, the peaks are re-centered around this summit, so will all be of width summits*2+1. If any of these newly re-centered peaks overlap, they will be merged, and hence will be wider than summits*2+1 bp.

It is possible to force recaluation of the summits, re-centering and merging, until all of the peaks have the same width:

tam <- dba(sampleSheet="tamoxifen.csv")
summitsize <- 1000
tam1 <- dba.count(tam, summits=summitsize)
centered <- dba.peakset(tam1, bRetrieve=TRUE)
while(!all(width(centered)==(summitsize*2+1))) {
  cat("RECENTER",length(centered),"\n")
  tam1 <- dba.count(tam, peaks=centered, summits=summitsize)
  centered <- dba.peakset(tam1, bRetrieve=TRUE)
  cat("RECENTERED",length(centered),"\n")
}

with output:

Computing summits...
Re-centering peaks...
RECENTER 2503 
Computing summits...
Re-centering peaks...
RECENTERED 2499 
RECENTER 2499 
Computing summits...
Re-centering peaks...
RECENTERED 2499
ADD REPLY
0
Entering edit mode

Thank you!

ADD REPLY
0
Entering edit mode

-redundant entry removed-

ADD REPLY
0
Entering edit mode

-redundant entry removed-

ADD REPLY

Login before adding your answer.

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