[BioC] ChIPpeakAnno makeVennDiagram problems

Vincent Schulz Vincent.Schulz at yale.edu
Wed May 22 19:47:21 CEST 2013


Hi,

I am having problems with ChIPpeakAnno makeVennDiagram problems when the regions of interest do not 
overlap.  This is coming up for me in comparing 4 datasets where two of the datasets don't overlap. 
  It would be great if the function could properly output 0 in the non-overlapping segments.

Thanks,

Vince


#toy example to show the issues
library(ChIPpeakAnno)


#this is OK
     peaks1 = RangedData(IRanges(start = c(1, 100, 200),
               end = c(2, 101, 201), names = c("Site1", "Site2", "Site3")),
               space = c("1", "1", "1"), strand=as.integer(1),feature=c("a","b","f"))
     peaks2 = RangedData(IRanges(start = c(1, 100, 200),
               end = c(2, 101, 201), names = c("Site1", "Site2", "Site3")),
               space = c("1", "1", "1"), strand=as.integer(1),feature=c("a","b","f"))
      makeVennDiagram(RangedDataList(peaks1,peaks2), NameOfPeaks=c("TF1", "TF2"),
       totalTest=100,scaled=F, euler.d=F)
#below gives error
     peaks1 = RangedData(IRanges(start = c(1, 100, 200),
               end = c(2, 101, 201), names = c("Site1", "Site2", "Site3")),
               space = c("1", "1", "1"), strand=as.integer(1),feature=c("a","b","f"))
     peaks2 = RangedData(IRanges(start = c(1, 100, 200),
               end = c(2, 101, 201), names = c("Site1", "Site2", "Site3")),
               space = c("2", "2", "2"), strand=as.integer(1),feature=c("a","b","f"))
      makeVennDiagram(RangedDataList(peaks1,peaks2), NameOfPeaks=c("TF1", "TF2"),
       totalTest=100,scaled=F, euler.d=F)
#Error in `colnames<-`(`*tmp*`, value = c("TF1", "chr", "TF2")) :
#  attempt to set 'colnames' on an object with less than two dimensions
#below gives error  (but it works in R2.15!)
     peaks1 = RangedData(IRanges(start = c(1, 100, 200),
               end = c(2, 101, 201), names = c("Site1", "Site2", "Site3")),
               space = c("1", "1", "1"), strand=as.integer(1),feature=c("a","b","f"))
     peaks2 = RangedData(IRanges(start = c(5, 105, 205),
               end = c(6, 106, 206), names = c("Site1", "Site2", "Site3")),
               space = c("1", "1", "1"), strand=as.integer(1),feature=c("a","b","f"))
      makeVennDiagram(RangedDataList(peaks1,peaks2), NameOfPeaks=c("TF1", "TF2"),
       totalTest=100,scaled=F, euler.d=F)
#Error in seq.default(cnt, length.out = counts[i]) :
#  length must be non-negative number
#In addition: Warning messages:
#1: In min(p1.inBoth, p2.inBoth) :
#  no non-missing arguments to min; returning Inf
#2: In findVennCounts(Peaks = Peaks, NameOfPeaks = NameOfPeaks, maxgap = maxgap,  :
#  negative counts generated when multiple peaks overlap with one peak!
#
sessionInfo()
R version 3.0.1 (2013-05-16)
Platform: x86_64-pc-linux-gnu (64-bit)

locale:
  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
  [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
  [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
  [7] LC_PAPER=C                 LC_NAME=C
  [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

attached base packages:
[1] parallel  grid      stats     graphics  grDevices utils     datasets
[8] methods   base

other attached packages:
  [1] RSvgDevice_0.6.4.2                  Cairo_1.5-2
  [3] ChIPpeakAnno_2.8.0                  GenomicFeatures_1.12.1
  [5] limma_3.16.4                        org.Hs.eg.db_2.9.0
  [7] GO.db_2.9.0                         RSQLite_0.11.3
  [9] DBI_0.2-7                           AnnotationDbi_1.22.5
[11] BSgenome.Ecoli.NCBI.20080805_1.3.17 BSgenome_1.28.0
[13] GenomicRanges_1.12.4                Biostrings_2.28.0
[15] IRanges_1.18.1                      multtest_2.16.0
[17] Biobase_2.20.0                      biomaRt_2.16.0
[19] BiocGenerics_0.6.0                  VennDiagram_1.6.0
[21] BiocInstaller_1.10.1

loaded via a namespace (and not attached):
  [1] bitops_1.0-5       MASS_7.3-26        RCurl_1.95-4.1     Rsamtools_1.12.3
  [5] rtracklayer_1.20.2 splines_3.0.1      stats4_3.0.1       survival_2.37-4
  [9] tcltk_3.0.1        tools_3.0.1        XML_3.96-1.1       zlibbioc_1.6.0



More information about the Bioconductor mailing list