Hi Walter -

 You did the right thing by explicitly calling dba.contrast to add the WT vs KO contrast as there are only two knockouts. However you have two different factors (trimethyl and monomethly, I assume these are histone marks) for each condition.

The warning from dba.analyze is that there were no differentially bound sites identified (with an FDR < 0.10 using edgeR) -- this is of course possible! Indeed as the sites for each of these two histone marks may not overlap very much, it is not too surprising The error you're seeing in calling dba.report is a typo — in the message you used a minus sign instead of an equal (assignment) sign.

There are a few things you could do here. You may want to check out the overlaps of the peaks:

> dba.plotVenn(rats,rats$condition$trimethly)
> dba.plotVenn(rats,rats$condition$monomethly)

To see if there are common peaks within each group being contrasted. After the analysis, you may want to  have a look at the MA plot (dba.plotMA) to make sure things got normalized OK, and to see if it looks like there are sites that really are different between the conditions. You can also examine the stats for all the sites:

> rats.DB = dba.report(rats, th=1)

This would let you know what sites are identified with the most confidence, even if none have a low enough FDR.

If you really do want to contrast all the mono- and tri-methly peaks together within each condition, you may want to try a multifactorial design, matching the marks across conditions:

> rats = dba.contrast(rats, categories=DBA_CONDITION,block=DBA_FACTOR)

When you run dba.analyze, you'll get both a single-factor analysis (as you have already done) and the matched analysis. To retrieve the stats for the multifactor analysis:

> rats.DB = dba.report(rats, method=DBA_EDGER_BLOCK, th=1)

There may be some more specific questions you can address with your data set, which doesn't have much replication (only monomethly WT is replicated, and that has only two replicates), using a more sophisticated multifactorial design, in which case you'll need to work with edgeR (and/or DESeq) directly.

Cheers-
Rory

From: Walter Taylor <Walter.Taylor@dartmouth.edu<mailto:Walter.Taylor@dartmouth.edu>>
Date: Thu, 31 Jan 2013 23:28:45 +0000
To: Rory Stark <rory.stark@cancer.org.uk<mailto:rory.stark@cancer.org.uk>>
Subject: a diffBind problem


Rory,

If you have time to take a quick look at my case, I would be grateful.  I have been able to get through most of the steps in creating a report in DiffBind with a fairly simple data set, but it usually reports that I have no differentially bound sites.

Here is my sample sheet:



And here is a copy of my commands in Rstudio:

> rats = dba(sampleSheet="schneid2.csv")
1 wt trimethyl wild type  1 raw
2 wt monomethyl wild type  1 raw
3 wt monomethyl wild type  2 raw
4 ko trimethyl knockout  1 raw
5 ko monomethyl knockout  1 raw
> rats = dba.count(rats)
Calculating library sizes from column totals.
> rats = dba.contrast(rats, categories=DBA_CONDITION)
Warning message:
No contrasts added. Perhaps try more categories, or lower value for minMembers.
> rats = dba.contrast(rats, categories=DBA_CONDITION, minMembers=2)
>
>
> rats = dba.analyze(rats)
Calculating library sizes from column totals.
Warning message:
In dba.analyze(rats) :
  No correlation heatmap plotted -- contrast 1 does not have enough differentially bound sites.
>
> rats.DB - dba.report(rats)
Error: object 'rats.DB' not found



I am using DiffBind 1.4.1


Any hints would be greatly appreciated.

Walter



Walter Taylor, PhD

Dartmouth-Hitchcock Medical Center
Norris Cotton Cancer Center
1 Medical Center Drive
Lebanon, NH  03756

walter.taylor@dartmouth.edu<mailto:walter.taylor@dartmouth.edu>
603-653-9174


	[[alternative HTML version deleted]]

