Diffbind dba.plotProfile attempt to select less than one element in OneIndex
1
0
Entering edit mode
bhanratt • 0
@bhanratt-15265
Last seen 2.6 years ago
United States

Not sure what's going on with this function. I assume it's a bug. dba.analyze() ran fine without errors but dba.plotProfile() threw this:


> DBA <- dba.analyze(samplesheet, bBlacklist=FALSE, bGreylist=FALSE)
Loading sample sheet...
58 1 H3K4me3 AD  1 macs
77 2 H3K4me3 AD  2 macs
78 3 H3K4me3 AD  3 macs
81 4 H3K4me3 AD  4 macs
92 5 H3K4me3 AD  5 macs
145.1 6 H3K4me3 NE  1 macs
145.2 7 H3K4me3 NE  2 macs
173.1 8 H3K4me3 NE  3 macs
49 9 H3K4me3 NE  4 macs
93 10 H3K4me3 NE  5 macs
Forming consensus peakset and counting reads...
Computing summits...
Re-centering peaks...
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Reads will be counted as Paired-end.
Normalize DESeq2 with defaults...
Forming default model design and contrast(s)...
Computing results names...
Analyzing...
gene-wise dispersion estimates
mean-dispersion relationship
final dispersion estimates
>
> DBA.profile <- dba.plotProfile(DBA, labels=DBA_ID)
Generating report-based DBA object...
Generating profiles...
Error in value[[3L]](cond) :
  profileplyr error: Error: stop worker failed:
  attempt to select less than one element in OneIndex
DiffBind • 1.3k views
ADD COMMENT
0
Entering edit mode
Rory Stark ★ 5.2k
@rory-stark-5741
Last seen 14 days ago
Cambridge, UK

I can't tell exactly what is going on from this description. It would be a good idea to check the result of the analysis prior to plotting by checking what happens when you print DBA. Another idea is to generate the report object used by dba.plotProfile() explicitly, and seeing what that looks like before passing it in.

Try running the following code and let me know what happens:

DBA <- dba.analyze(samplesheet, bBlacklist=FALSE, bGreylist=FALSE)
DBA
DBA.report <- dba.report(DBA, bDB=TRUE, bGain=TRUE, bLoss=TRUE, bAll=FALSE)
DBA.report
DBA$config$RunParallel <- FALSE
DBA.profile <- dba.plotProfile(DBA, labels=DBA_ID, sites=DBA.report)
ADD COMMENT
0
Entering edit mode
> DBA
10 Samples, 31953 sites in matrix:
      ID Tissue  Factor Condition Replicate    Reads FRiP
1     58      1 H3K4me3        AD         1 25947608 0.39
2     77      2 H3K4me3        AD         2 37025224 0.46
3     78      3 H3K4me3        AD         3 26933582 0.38
4     81      4 H3K4me3        AD         4 28471012 0.41
5     92      5 H3K4me3        AD         5 35347224 0.39
6  145.1      6 H3K4me3        NE         1 27172680 0.35
7  145.2      7 H3K4me3        NE         2 26983321 0.42
8  173.1      8 H3K4me3        NE         3 32453960 0.41
9     49      9 H3K4me3        NE         4 29672639 0.31
10    93     10 H3K4me3        NE         5 28018194 0.38

Design: [~Condition] | 1 Contrast:
     Factor Group Samples Group2 Samples2 DB.DESeq2
1 Condition    NE       5     AD        5      7577
> DBA.report <- dba.report(DBA, bDB=TRUE, bGain=TRUE, bLoss=TRUE, bAll=FALSE)
Generating report-based DBA object...
> DBA.report
2 Samples, 7577 sites in matrix:
   Contrast Direction DB Method Intervals
1 NE vs. AD      Gain DB DESeq2      5175
2 NE vs. AD      Loss DB DESeq2      2402
> DBA$config$RunParallel <- FALSE
> DBA.profile <- dba.plotProfile(DBA, labels=DBA_ID, sites=DBA.report)
Generating profiles...
Error in value[[3L]](cond) : 
  profileplyr error: Error in .width_as_unnamed_integer(width, msg = "an end that is greater or equal to its start minus one"): each range must have an end that is greater or equal to its start minus
  one
In addition: Warning message:
In .Seqinfo.mergexy(x, y) :
  Each of the 2 combined objects has sequence levels not in the other:
  - in 'x': chr1_KI270714v1_random
  - in 'y': chr12, chr13, chr14, chr14_GL000009v2_random, chr14_KI270722v1_random, chr15, chr15_KI270727v1_random, chr16, chr17, chr18, chr19
  Make sure to always combine/compare objects based on the same reference
  genome (use suppressWarnings() to suppress this warning).
ADD REPLY

Login before adding your answer.

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