search for: nummatrixlik

Displaying 3 results from an estimated 3 matches for "nummatrixlik".

Did you mean: nummatrixlike
2016 Sep 10
3
c(<Matrix>, <Matrix>) / help(dotsMethods) etc
...:1), matrix(10:11)) and that's not so easy, e.g., the following class and method definitions do *not* achieve the desired result: ## "mMatrix" is already hidden in Matrix pkg: setClassUnion("mMatrix", members = c("matrix", "Matrix")) setClassUnion("numMatrixLike", members = c("logical", "integer","numeric", "mMatrix")) c.Matrix <- function(...) unlist(lapply(list(...), as.vector)) ## NB: Must use signature '(x, ..., recursive = FALSE)' : setMethod("c", "Matrix"...
2016 Sep 10
1
c(<Matrix>, <Matrix>) / help(dotsMethods) etc
...ing class and method >> definitions do *not* achieve the desired result: >> >> ## "mMatrix" is already hidden in Matrix pkg: >> setClassUnion("mMatrix", members = c("matrix", "Matrix")) >> setClassUnion("numMatrixLike", members = >> c("logical", "integer","numeric", "mMatrix")) >> >> c.Matrix <- function(...) unlist(lapply(list(...), as.vector)) >> ## NB: Must use signature '(x, ..., recursive = FALSE)' : &gt...
2016 Sep 10
0
c(<Matrix>, <Matrix>) / help(dotsMethods) etc
...that's not so easy, e.g., the following class and method > definitions do *not* achieve the desired result: > > ## "mMatrix" is already hidden in Matrix pkg: > setClassUnion("mMatrix", members = c("matrix", "Matrix")) > setClassUnion("numMatrixLike", members = > c("logical", "integer","numeric", "mMatrix")) > > c.Matrix <- function(...) unlist(lapply(list(...), as.vector)) > ## NB: Must use signature '(x, ..., recursive = FALSE)' : > setMethod("c&q...