Question: Error in assign while calling the vmatchPattern function
0
gravatar for mattia pelizzola
10.8 years ago by
mattia pelizzola200 wrote:
Hi, I have a recurrent but not reproducible error.. If I run the same piece of code twice the error will disappear, but it will likely shop up the day after. This is the error message: Error in assign(".defined", method at defined, envir = envir) : formal argument "envir" matched by multiple actual arguments Calls: vmatchPattern ... lapply -> FUN -> loadMethod -> loadMethod -> assign this is the code where the error show up calling the vmatchPattern function for one chromosome. The code is actually repeated several times for all the chromosomes during the same R session: chrseq=Hsapiens$chr1 Gviews = Views(chrseq, starts, ends) # where length(starts)> 20000 Gset = DNAStringSet(Gviews) querySeq=DNAString('ATTH') a = startIndex(vmatchPattern(querySeq, Gset, fixed=F)) and finally this is my sessionInfo: R version 2.8.1 (2008-12-22) x86_64-unknown-linux-gnu locale: LC_CTYPE=en_US.UTF-8;LC_NUMERIC=C;LC_TIME=en_US.UTF-8;LC_COLLATE=en_US .UTF-8;LC_MONETARY=C;LC_MESSAGES=en_US.UTF-8;LC_PAPER=en_US.UTF-8;LC_N AME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.UTF-8;LC_IDENTI FICATION=C attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] BSgenome.Hsapiens.UCSC.hg18_1.3.11 BSgenome_1.10.3 [3] Biostrings_2.10.15 IRanges_1.0.11 loaded via a namespace (and not attached): [1] grid_2.8.1 lattice_0.17-17 Matrix_0.999375-20 thanks, mattia
bsgenome • 418 views
ADD COMMENTlink modified 10.8 years ago by Hans-Ulrich Klein330 • written 10.8 years ago by mattia pelizzola200
Answer: Error in assign while calling the vmatchPattern function
0
gravatar for Hans-Ulrich Klein
10.8 years ago by
United States
Hans-Ulrich Klein330 wrote:
Hi all, I encountered a similar (probably related) error today. I wanted to match a few hundred sequences against the UCSC genome from the package "BSgenome.Hsapiens.UCSC.hg18". I implemented a simple "for" loop and called seq = DNAString(sequences$Sequence[i]) matchRes = matchPattern(seq, Hsapiens[[chr]]) SurroundingSequence[i] = as.character(subseq(Hsapiens[[chr]], start=start(matchRes)-250, end=end(matchRes)+250)) within the loop. In run i=187 I get the error message: Error in assign(".target", method at target, envir = envir) : formal argument "envir" matched by multiple actual arguments Calls: as.character ... RawPtr.read -> dec_lkup -> loadMethod -> loadMethod -> assign However, it works when I match the 187th sequence manually (without matching the 186 other sequences before). That makes it hard to debug. Best wishes, Hans-Ulrich PS: my session info: > sessionInfo() R version 2.8.1 (2008-12-22) x86_64-pc-linux-gnu locale: C attached base packages: [1] stats graphics grDevices utils datasets methods base other attached packages: [1] BSgenome.Hsapiens.UCSC.hg18_1.3.11 BSgenome_1.10.3 [3] Biostrings_2.10.16 IRanges_1.0.12 loaded via a namespace (and not attached): [1] Matrix_0.999375-21 grid_2.8.1 lattice_0.17-20 tools_2.8.1 mattia pelizzola wrote: > Hi, > > I have a recurrent but not reproducible error.. If I run the same > piece of code twice the error will disappear, but it will likely shop > up the day after. > This is the error message: > > Error in assign(".defined", method at defined, envir = envir) : > formal argument "envir" matched by multiple actual arguments > Calls: vmatchPattern ... lapply -> FUN -> loadMethod -> loadMethod -> assign > > this is the code where the error show up calling the vmatchPattern > function for one chromosome. The code is actually repeated several > times for all the chromosomes during the same R session: > > chrseq=Hsapiens$chr1 > Gviews = Views(chrseq, starts, ends) # where length(starts)> 20000 > Gset = DNAStringSet(Gviews) > querySeq=DNAString('ATTH') > a = startIndex(vmatchPattern(querySeq, Gset, fixed=F)) > > > > and finally this is my sessionInfo: > > R version 2.8.1 (2008-12-22) > x86_64-unknown-linux-gnu > > locale: > LC_CTYPE=en_US.UTF-8;LC_NUMERIC=C;LC_TIME=en_US.UTF-8;LC_COLLATE=en_ US.UTF-8;LC_MONETARY=C;LC_MESSAGES=en_US.UTF-8;LC_PAPER=en_US.UTF-8;LC _NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.UTF-8;LC_IDEN TIFICATION=C > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > > other attached packages: > [1] BSgenome.Hsapiens.UCSC.hg18_1.3.11 BSgenome_1.10.3 > [3] Biostrings_2.10.15 IRanges_1.0.11 > > loaded via a namespace (and not attached): > [1] grid_2.8.1 lattice_0.17-17 Matrix_0.999375-20 > > > > thanks, > > mattia > >
ADD COMMENTlink written 10.8 years ago by Hans-Ulrich Klein330
Hi Mattia, Hans-Ulrich, Thanks for reporting this. I'm aware of the problem. It shows up sometimes on the build/check report e.g. today: http://bioconductor.org/checkResults/2.3/bioc- LATEST/BSgenome/wilson2-buildsrc.html Some days it's here, some days no, sometimes on one platform, sometimes on the other. It's a weird issue that is indeed very hard to reproduce as you noticed. I'll keep you posted when I find something. Cheers, H. Hans-Ulrich Klein wrote: > Hi all, > > I encountered a similar (probably related) error today. I wanted to > match a few hundred sequences against the UCSC genome from the package > "BSgenome.Hsapiens.UCSC.hg18". I implemented a simple "for" loop and called > > seq = DNAString(sequences$Sequence[i]) > matchRes = matchPattern(seq, Hsapiens[[chr]]) > SurroundingSequence[i] = as.character(subseq(Hsapiens[[chr]], > start=start(matchRes)-250, end=end(matchRes)+250)) > > within the loop. In run i=187 I get the error message: > Error in assign(".target", method at target, envir = envir) : > formal argument "envir" matched by multiple actual arguments > Calls: as.character ... RawPtr.read -> dec_lkup -> loadMethod -> > loadMethod -> assign > > However, it works when I match the 187th sequence manually (without > matching the 186 other sequences before). That makes it hard to debug. > > Best wishes, > Hans-Ulrich > > PS: my session info: > > sessionInfo() > R version 2.8.1 (2008-12-22) > x86_64-pc-linux-gnu > > locale: > C > > attached base packages: > [1] stats graphics grDevices utils datasets methods base > other attached packages: > [1] BSgenome.Hsapiens.UCSC.hg18_1.3.11 BSgenome_1.10.3 > [3] Biostrings_2.10.16 IRanges_1.0.12 > loaded via a namespace (and not attached): > [1] Matrix_0.999375-21 grid_2.8.1 lattice_0.17-20 tools_2.8.1 > > > mattia pelizzola wrote: >> Hi, >> >> I have a recurrent but not reproducible error.. If I run the same >> piece of code twice the error will disappear, but it will likely shop >> up the day after. >> This is the error message: >> >> Error in assign(".defined", method at defined, envir = envir) : >> formal argument "envir" matched by multiple actual arguments >> Calls: vmatchPattern ... lapply -> FUN -> loadMethod -> loadMethod -> >> assign >> >> this is the code where the error show up calling the vmatchPattern >> function for one chromosome. The code is actually repeated several >> times for all the chromosomes during the same R session: >> >> chrseq=Hsapiens$chr1 >> Gviews = Views(chrseq, starts, ends) # where length(starts)> 20000 >> Gset = DNAStringSet(Gviews) >> querySeq=DNAString('ATTH') >> a = startIndex(vmatchPattern(querySeq, Gset, fixed=F)) >> >> >> >> and finally this is my sessionInfo: >> >> R version 2.8.1 (2008-12-22) >> x86_64-unknown-linux-gnu >> >> locale: >> LC_CTYPE=en_US.UTF-8;LC_NUMERIC=C;LC_TIME=en_US.UTF-8;LC_COLLATE=en _US.UTF-8;LC_MONETARY=C;LC_MESSAGES=en_US.UTF-8;LC_PAPER=en_US.UTF-8;L C_NAME=C;LC_ADDRESS=C;LC_TELEPHONE=C;LC_MEASUREMENT=en_US.UTF-8;LC_IDE NTIFICATION=C >> >> >> attached base packages: >> [1] stats graphics grDevices utils datasets methods base >> >> other attached packages: >> [1] BSgenome.Hsapiens.UCSC.hg18_1.3.11 BSgenome_1.10.3 >> [3] Biostrings_2.10.15 IRanges_1.0.11 >> >> loaded via a namespace (and not attached): >> [1] grid_2.8.1 lattice_0.17-17 Matrix_0.999375-20 >> >> >> >> thanks, >> >> mattia >> >> > > _______________________________________________ > Bioconductor mailing list > Bioconductor at stat.math.ethz.ch > https://stat.ethz.ch/mailman/listinfo/bioconductor > Search the archives: > http://news.gmane.org/gmane.science.biology.informatics.conductor -- Hervé Pagès Program in Computational Biology Division of Public Health Sciences Fred Hutchinson Cancer Research Center 1100 Fairview Ave. N, M2-B876 P.O. Box 19024 Seattle, WA 98109-1024 E-mail: hpages at fhcrc.org Phone: (206) 667-5791 Fax: (206) 667-1319
ADD REPLYlink written 10.8 years ago by Hervé Pagès ♦♦ 14k
Please log in to add an answer.

Help
Access

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.
Powered by Biostar version 16.09
Traffic: 138 users visited in the last hour