# SCM Repository

[matrix] Diff of /pkg/R/Auxiliaries.R
 [matrix] / pkg / R / Auxiliaries.R # Diff of /pkg/R/Auxiliaries.R

revision 1270, Thu May 18 06:44:43 2006 UTC revision 1280, Tue May 23 08:01:44 2006 UTC
# Line 148  Line 148
148          return(unique(cbind(x@i,x@j)))          return(unique(cbind(x@i,x@j)))
149      ## else:      ## else:
150      isC <- any("i" == slotNames(x))# is Csparse (not Rsparse)      isC <- any("i" == slotNames(x))# is Csparse (not Rsparse)
151      .Call("compressed_non_0_ij", x, isC, PACKAGE = "Matrix")      .Call(compressed_non_0_ij, x, isC)
152  }  }
153
154  ## nr= nrow: since  i in {0,1,.., nrow-1}  these are 1:1 "decimal" encodings:  ## nr= nrow: since  i in {0,1,.., nrow-1}  these are 1:1 "decimal" encodings:
# Line 188  Line 188
188  uniq <- function(x) {  uniq <- function(x) {
189
190  ### Note: maybe, using  ### Note: maybe, using
191  ### ----    xj <- .Call("Matrix_expand_pointers", x@p)  ### ----    xj <- .Call(Matrix_expand_pointers, x@p)
192  ### would be slightly more efficient than as( <dgC> , "dgTMatrix")  ### would be slightly more efficient than as( <dgC> , "dgTMatrix")
193  ### but really efficient would be to use only one .Call(.) for uniq(.) !  ### but really efficient would be to use only one .Call(.) for uniq(.) !
194  ### Try to do it particularly fast for the case where 'x' is already a 'uniq' <dgT>  ### Try to do it particularly fast for the case where 'x' is already a 'uniq' <dgT>

Legend:
 Removed from v.1270 changed lines Added in v.1280  