Copy Number Variation in the cn.mops Package
2
0
Entering edit mode
@bioconductor-8383
Last seen 9.4 years ago

Hi all,
 

I'm trying to detect CNVs in different NGS samples for a single gene, so the the .bam files are not necessarily huge. I am, however, running into what *I think* is a syntax error below. Not quite sure what I'm doing wrong. Any input will be greatly appreciated.

Thanks.

OAO

> BAMFiles = list.files(pattern=".bam$")
> bamDataRanges = getReadCountsFromBAM(BAMFiles, sampleNames=paste("Sample",1:

3),WL = 5000, mode="paired")
Identified the following reference sequences:  chr7,chr20
Missing "refSeqName"! Selecting chr7 as reference sequence.
Using indexed BAM files.
Reading file: 001_sorted.bam
  chr7


Reading file: 002_sorted.bam
  chr7


Reading file: 003_sorted.bam
  chr7


Error in which(is.na(prov_ids) & .hasPrefix(seqlevels, prefix)) :
  error in evaluating the argument 'x' in selecting a method for function 'which': Error in nchar(prefix) :
  could not find symbol "keepNA" in environment of the generic function

> sessionInfo()
R version 3.2.0 (2015-04-16)
Platform: i386-w64-mingw32/i386 (32-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

locale:
[1] LC_COLLATE=English_xxx  LC_CTYPE=English_xxx  
[3] LC_MONETARY=English_xxx LC_NUMERIC=C                        
[5] LC_TIME=English_xxx   

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

other attached packages:
[1] cn.mops_1.14.0       GenomicRanges_1.20.5 GenomeInfoDb_1.4.1 
[4] IRanges_2.2.5        S4Vectors_0.6.1      Biobase_2.28.0     
[7] BiocGenerics_0.14.0

loaded via a namespace (and not attached):
[1] zlibbioc_1.14.0   XVector_0.8.0     Biostrings_2.36.1 Rsamtools_1.20.4
[5] bitops_1.0-6    
>

cn.mops cnv cnvtools • 2.6k views
ADD COMMENT
0
Entering edit mode
@gunter-klambauer-5426
Last seen 3.8 years ago
Austria

Hello OAO,

The function "getReadCountsFromBAM" is a wrapper for Rsamtools::countBam. I think the problem lies somewhere there.. can you give me the results of "traceback()" after the error occurs? Are you sure everything is ok with your BAM files?

 

Regards,

Günter

ADD COMMENT
0
Entering edit mode
@gunter-klambauer-5426
Last seen 3.8 years ago
Austria

Via email:

###############################################

Hi Gunter,
 

Ran 'traceback()':

> traceback()
13: which(is.na(prov_ids) & .hasPrefix(seqlevels, prefix))
12: assignProvIdsForSuperGroup(seqlevels, "CHR")
11: rankSeqlevels(x, X.is.sexchrom = X.is.sexchrom)
10: eval(expr, envir, enclos)
9: eval(quote(list(...)), env)
8: eval(quote(list(...)), env)
7: standardGeneric("order")
6: order(rankSeqlevels(x, X.is.sexchrom = X.is.sexchrom))
5: sortSeqlevels(seqlevels(x), X.is.sexchrom = X.is.sexchrom)
4: sortSeqlevels(seqlevels(x), X.is.sexchrom = X.is.sexchrom)
3: sortSeqlevels(gr)
2: sortSeqlevels(gr)
1: getReadCountsFromBAM(BAMFiles, sampleNames = paste("Sample",
       1:3), WL = 5000, mode = "paired", parallel = 0)
>

Regards,

Voke

###############################################

 

I think the problem occured somewhere in the logic of "Rsamtools" - could you please post this problem to the support page of "Rsamtools"?

 

Regards,

Günter

 

 

 

ADD COMMENT
2
Entering edit mode

This has come up several times recently. It seems very strange. The solution so far, e.g., at VariantAnnotation: scanVcfHeader() throws error about missing keepNA has been to update to R-3.2.1.

ADD REPLY
0
Entering edit mode

Thanks for helping me out here, Martin!

Regards,

Günter

ADD REPLY
0
Entering edit mode

Thank you Martin. That worked!

ADD REPLY
0
Entering edit mode

Thanks Gunter.

-OAO

ADD REPLY
0
Entering edit mode

Hello Voke,

Apologies - I pointed you towards "Rsamtools"... But the function "sortSeqlevels" comes from the package "GenomeInfoDb"..

 

Regards,

Günter

ADD REPLY
0
Entering edit mode

Thanks Gunter. I have edited my subsequent post.

-OAO

ADD REPLY

Login before adding your answer.

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