similar to: methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error

Displaying 20 results from an estimated 900 matches similar to: "methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error"

2019 Jul 01
1
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true
I run checks with R-devel rev. 76756 on several of my packages which use S4, with no ill effects. With the risk of not adding much, it seems that Martin's example, which I repeat below, suggests a crossover between several "signatures" involved here - the signature of the generic, the signature of the method (the argument for setMethod()), and the signature of the function object
2019 Jun 29
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> Martin Maechler >>>>> on Sat, 29 Jun 2019 12:05:49 +0200 writes: >>>>> Martin Maechler >>>>> on Sat, 29 Jun 2019 10:33:10 +0200 writes: >>>>> peter dalgaard >>>>> on Fri, 28 Jun 2019 16:20:03 +0200 writes: >>> > On 28 Jun 2019, at 16:03 , Martin Maechler <maechler at
2019 Jun 29
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> Martin Maechler >>>>> on Sat, 29 Jun 2019 10:33:10 +0200 writes: >>>>> peter dalgaard >>>>> on Fri, 28 Jun 2019 16:20:03 +0200 writes: >> > On 28 Jun 2019, at 16:03 , Martin Maechler <maechler at stat.math.ethz.ch> wrote: >> > >> >>>>>> Henrik Bengtsson
2019 Jun 29
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> peter dalgaard >>>>> on Fri, 28 Jun 2019 16:20:03 +0200 writes: > > On 28 Jun 2019, at 16:03 , Martin Maechler <maechler at stat.math.ethz.ch> wrote: > > > >>>>>> Henrik Bengtsson > >>>>>> on Thu, 27 Jun 2019 16:00:39 -0700 writes: > > > >> Using: > >> > >>
2019 Jun 27
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
Using: untrace(methods::conformMethod) at <- c(12,4,3,2) str(body(methods::conformMethod)[[at]]) ## language omittedSig <- omittedSig && (signature[omittedSig] != "missing") cc <- 0L trace(methods::conformMethod, tracer = quote({ cc <<- cc + 1L print(cc) if (cc == 31) { ## manually identified untrace(methods::conformMethod)
2019 Jun 28
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
> On 28 Jun 2019, at 16:03 , Martin Maechler <maechler at stat.math.ethz.ch> wrote: > >>>>>> Henrik Bengtsson >>>>>> on Thu, 27 Jun 2019 16:00:39 -0700 writes: > >> Using: >> >> untrace(methods::conformMethod) >> at <- c(12,4,3,2) >> str(body(methods::conformMethod)[[at]]) >> ## language omittedSig
2019 Jun 28
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> Henrik Bengtsson >>>>> on Thu, 27 Jun 2019 16:00:39 -0700 writes: > Using: > > untrace(methods::conformMethod) > at <- c(12,4,3,2) > str(body(methods::conformMethod)[[at]]) > ## language omittedSig <- omittedSig && (signature[omittedSig] != "missing") > cc <- 0L > trace(methods::conformMethod, tracer =
2019 Jun 27
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
Henrik, If a minimal reprex is hard to construct, could you perhaps instrument your version of R to include a browser() call at the start of the else if(!all(signature[omittedSig] == "missing")) { branch, run the code that triggers the issue for you (and must hit that branch) and tell us what the "signature" and "omittedSig" objects look like at that point?
2019 Jun 25
3
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
**Maybe this bug needs to be understood further before applying the patch because patch is most likely also wrong** Because, from just looking at the expressions, I think neither the R 3.6.0 version: omittedSig <- omittedSig && (signature[omittedSig] != "missing") nor the patched version (I proposed): omittedSig <- omittedSig & (signature[omittedSig] !=
2019 Jun 23
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
Thank you. To correct myself, I can indeed reproduce this with R --vanilla too. A reproducible example is: $ R --vanilla R version 3.6.0 Patched (2019-05-31 r76629) -- "Planting of a Tree" ... > Sys.setenv("_R_CHECK_LENGTH_1_LOGIC2_" = "true") > loadNamespace("oligo") Error in omittedSig && (signature[omittedSig] != "missing") :
2019 Jun 22
2
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
DISCLAIMER: I can not get this error with R --vanilla, so it only occurs when some other package is also loaded. I don't have time to find to narrow that down for a reproducible example, but I believe the following error in R 3.6.0: > Sys.setenv("_R_CHECK_LENGTH_1_LOGIC2_" = "true") > library(oligo) Error in omittedSig && (signature[omittedSig] !=
2019 Jun 24
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> Henrik Bengtsson via R-core >>>>> on Sun, 23 Jun 2019 11:29:58 -0700 writes: > Thank you. > To correct myself, I can indeed reproduce this with R --vanilla too. > A reproducible example is: > $ R --vanilla > R version 3.6.0 Patched (2019-05-31 r76629) -- "Planting of a Tree" > ... >>
2019 Jun 25
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
Argh! Yes you are right, the "fix" doesn't. And I fell into the same "hey it's a vector so && has to be wrong"-trap. So this has to be reverted to something that has at least failed unconspicuously for a decade.... Will do. Thanks to Martin for remaining suspicious! [This code was originally from 2009, by John Chambers. It is not too likely that he'll
2019 Jun 27
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
>>>>> peter dalgaard >>>>> on Thu, 27 Jun 2019 16:23:14 +0200 writes: > Henrik, > If a minimal reprex is hard to construct, could you perhaps instrument your version of R to include a browser() call at the start of the > else if(!all(signature[omittedSig] == "missing")) { > branch, run the code that triggers the issue
2019 Jun 23
0
methods package: A _R_CHECK_LENGTH_1_LOGIC2_=true error
This looks obvious enough, so I just committed your fix to R-devel and R-patched. I'm at the wrong machine for thorough testing, but at least it seems to build OK. However, I sense some risk that this could uncover sleeping bugs elsewhere, so watch out. -pd > On 22 Jun 2019, at 18:49 , Henrik Bengtsson <henrik.bengtsson at gmail.com> wrote: > > DISCLAIMER: I can not get this
2006 Mar 14
1
setMethod confusion
Hello I've checked through previous postings but don't see a fully equivalent problem-just a few hints. I have been trying to set a new method for the existing function "table" or "as.data.frame.table" for my class "tfSites". Taking out all the useful code and just returning the input class I get the error setMethod("table",
2006 Mar 15
1
setMethod confusion -best reference for S4 programming
Thanks I think you have both answered my question (reckon Ill go S3 on that). As an adjunct to this do you know what might be the best reference to the S4 methods current implementation. I have ordered the Chambers book "Programming with Data", and I have a short tutorial-- "S4 Classes in 15 pages, more or less". Have I missed any other useful resources? Stephen Henderson
2007 Apr 02
0
Object problems with Generic and rematchDefinition
Hello all, Let me try this again with some code. I am trying to make a new object and it's not working. I get : Error in rematchDefinition(definition, fdef, mnames, fnames, signature) : methods can add arguments to the generic only if '...' is an argument to the generic as my error. I have included my code. It is from the xcms package. Any help would be great even if
2011 Feb 05
1
Seeking help to define method for '+'
Dear all, I am trying to define "+" method for my newly defined s4 class which is as follows: setClass("Me", sealed=F,representation(x1 = "numeric", x2 = "character")) new1 <- new("Me", x1=2, x2="comment1") new2 <- new("Me", x1=3, x2="comment1") setMethod("+", "Me",
2005 Nov 18
3
Method for $
Dear R experts, I have defined a class "myclass" and would like the slots to be extractable not only by "@" but also by "$". I now try to write a method for "$" that simply executes the request object at slotname, whenever someone calls object$slotname for any object of class "myclass". I don't manage to find out how I can provide this