Got the following error while working with the DNaseR package; Error in NSBS(i, x, exact = exact, upperBoundIsStrict = !allow.append) : subscript contains NAs or out-of-bounds indices
0
0
Entering edit mode
@martinmullis91-7446
Last seen 10.8 years ago
United States

I'm currently working with the DNaseR package but am having issues performing the footprinting analysis of the DNase Seq data in the specified .bam file. 

 I performed the example code from ?DNaseR as a test and everything worked well: 

> library('DNaseR')

> bamfile <- "chrY_3Kb_wgEncodeUwDgfTh1Aln.bam"

> f <- system.file("extdata", bamfile, package="DNaseR",mustWork= TRUE)

> dgf <- footprints(bam = f, chrN = "chrY", chrL = 3e6, p = 1e-9, width = c(6,40), N=2e6)

To save space, I have omitted the output of  >dgf, but it looked fine. 

 

Next, I tried to load another file using the following lines:

>setwd('~/Documents/Bam Files')

>bamfile <- '~/Documents/Bam Files/mybamfile.bam'

>bam.fp <- footprints(bam = bamfile, chrN = "chrY", chrL = 1.5e7, p=1e-9, width = c(6,50), N = 1e5)

...And I received the following error: 

Error in NSBS(i, x, exact = exact, upperBoundIsStrict = !allow.append) : 
  subscript contains NAs or out-of-bounds indices

I can't find much information on NSBS or S4Vectors, the package that contains it. As a result I'm not really sure what this error is referring to or how to fix it.

Here's my sessionInfo, in case that helps.

> sessionInfo()
R version 3.1.2 (2014-10-31)
Platform: x86_64-apple-darwin13.4.0 (64-bit)

locale:
[1] en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8

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

other attached packages:
[1] DNaseR_1.4.0         IRanges_2.0.1        S4Vectors_0.4.0      BiocGenerics_0.12.1 
[5] BiocInstaller_1.16.1

loaded via a namespace (and not attached):
[1] Biostrings_2.34.1    bitops_1.0-6         GenomeInfoDb_1.2.4   GenomicRanges_1.18.4
[5] Rsamtools_1.18.3     tools_3.1.2          XVector_0.6.0        zlibbioc_1.12.0     

 Thanks in advance for any help with this problem! 

Martin

dnaser • 1.4k views
ADD COMMENT

Login before adding your answer.

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