SCM

SCM Repository

[matrix] Diff of /pkg/R/dtpMatrix.R
ViewVC logotype

Diff of /pkg/R/dtpMatrix.R

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 627, Mon Mar 7 17:36:38 2005 UTC revision 628, Thu Mar 10 17:57:47 2005 UTC
# Line 13  Line 13 
13  setMethod("%*%", signature(x = "dtpMatrix", y = "dgeMatrix"),  setMethod("%*%", signature(x = "dtpMatrix", y = "dgeMatrix"),
14            function(x, y) .Call("dtpMatrix_dgeMatrix_mm", x, y))            function(x, y) .Call("dtpMatrix_dgeMatrix_mm", x, y))
15  setMethod("%*%", signature(x = "dgeMatrix", y = "dtpMatrix"),  setMethod("%*%", signature(x = "dgeMatrix", y = "dtpMatrix"),
16            function(x, y) callGeneric(x, as(y, "dgeMatrix")))            function(x, y) .Call("dgeMatrix_dtpMatrix_mm", x, y))
17    ## "matrix"
18  setMethod("%*%", signature(x = "dtpMatrix", y = "matrix"),  setMethod("%*%", signature(x = "dtpMatrix", y = "matrix"),
19            function(x, y) .Call("dtpMatrix_matrix_mm", x, y))            function(x, y) .Call("dtpMatrix_matrix_mm", x, y))# result = "matrix"
20  ## extending to vector RHS  setMethod("%*%", signature(x = "matrix", y = "dtpMatrix"),
21  setMethod("%*%", signature(x = "dtpMatrix", y = "numeric"),            function(x, y) callGeneric(as(x,"dgeMatrix"), y))# result: "dgeMatrix"
22            function(x, y) callGeneric(x, as.matrix(y)))  
23  ## the other way around  ## "numeric" (same as "dgeMatrix")
24  setMethod("%*%", signature(x = "numeric", y = "dtpMatrix"),  setMethod("%*%", signature(x = "dtpMatrix", y = "numeric"), .M.n)
25            function(x, y) callGeneric(as(as.matrix(x), "dgeMatrix"), y))  setMethod("%*%", signature(x = "numeric", y = "dtpMatrix"), .n.M)
26    
27  setMethod("determinant", signature(x = "dtpMatrix", logarithm = "missing"),  setMethod("determinant", signature(x = "dtpMatrix", logarithm = "missing"),
28            function(x, logarithm, ...) determinant(x, TRUE))            function(x, logarithm, ...) determinant(x, TRUE))

Legend:
Removed from v.627  
changed lines
  Added in v.628

root@r-forge.r-project.org
ViewVC Help
Powered by ViewVC 1.0.0  
Thanks to:
Vienna University of Economics and Business Powered By FusionForge