# SCM Repository

[matrix] Diff of /pkg/TODO
 [matrix] / pkg / TODO

# Diff of /pkg/TODO

revision 1592, Thu Sep 28 15:31:17 2006 UTC revision 1887, Thu Jun 7 09:04:34 2007 UTC
# Line 56  Line 56
56    calling Lapack's DGEMM for "dense"    calling Lapack's DGEMM for "dense"
57    [2005-12-xx: done for dgeMatrix at least]    [2005-12-xx: done for dgeMatrix at least]
58
- "ltTmatrix" :
2) new("ltTMatrix", diag = "U", Dim = c(2:2, 2:2)) shows lack of ltTM*_validate

59  - BUGlet:  Shouldn't lose factorization here:  - BUGlet:  Shouldn't lose factorization here:
60    h6 <- Hilbert(6); chol(h6) ; str(h6) # has factor    h6 <- Hilbert(6); chol(h6) ; str(h6) # has factor
61    str(H6 <- as(h6, "dspMatrix"))       # has lost factor    str(H6 <- as(h6, "dspMatrix"))       # has lost factor
62    ## and the same in a similar situation involving  "dpo", "dpp"    ## and the same in a similar situation involving  "dpo", "dpp"
63
- "Compare" for dgC & dgT  --- want to be able to do  M[M > 10]  etc

64  - Things like  M[upper.tri(M)] are not really most useful for  sparse  - Things like  M[upper.tri(M)] are not really most useful for  sparse
65    matrices.  --> provide generic functions    matrices.  --> provide generic functions
66    upperTriMatrix(), lowerTriMatrix()  both with argument  'diag = TRUE'    upperTriMatrix(), lowerTriMatrix()  both with argument  'diag = TRUE'
# Line 74  Line 69
69
70  - Factorizations: LU done; also Schur()  for  *sparse*  Matrices.  - Factorizations: LU done; also Schur()  for  *sparse*  Matrices.
71
72  - band(), triu(), tril() for *all*, not just sparse matrices  - band(), triu(), tril() for *all* including "matrix", not just sparse matrices
73
74  - is.na() method for all our matrices [ ==> which(*, arr.ind=TRUE) might work ]  - is.na() method for all our matrices [ ==> which(*, arr.ind=TRUE) might work ]
75
# Line 84  Line 79
79          setAs("dppMatrix", "sparseMatrix")          setAs("dppMatrix", "sparseMatrix")
80          setAs("dtpMatrix", "sparseMatrix")          setAs("dtpMatrix", "sparseMatrix")
81    and the same for "lsp" , "ltp"  and  "nsp" , "ntp" !    and the same for "lsp" , "ltp"  and  "nsp" , "ntp" !
82
83    - use  .Call(Csparse_drop, M, tol) in more places,
84      both with 'tol = 0.' to drop "values that happen to be 0" and for
85      zapsmall() methods for Csparse*
86
87    - implement .Call(Csparse_scale, ....) interfacing to cholmod_scale()
88      in src/CHOLMOD/Include/cholmod_matrixops.h : for another function
89      specifically for multiplying a cholmod_sparse object by a diagonal matrix.
90      Use it in %*% and [t]crossprod methods.
91
92    - chol() and determinant() should ``work'': proper result or "good" error
93      message.
94
95    - Think of constructing  setAs(...) calls automatically in order to
96      basically enable all ``sensible'' as(fromMatrix, toMatrix)  calls,
97      possibly using canCoerce(.)
98
99    - make sure *all* group methods have (maybe "bail-out") setMethod for "Matrix".
100      e.g. zapsmall(<pMatrix>) fails "badly"
101
102    - speedup: pass class definition to non0ind() [check all calls ..]
103
104    - sum(): implement methods which work for *all* our matrices.
105
106    - Implement  expand(.) for the Cholesky() results
107      "dCHMsimpl" and  "dCHMsuper"  -- currently have no *decent* way to get at
108      the matrix factors of the corresponding matrix factorization !!
109
110    - rbind(<sparse>, <dense>) does not work  (e.g. <dgC>, <dge>)
111
112    - setAs(<Mcl>,  "[dln]Matrix" )  for <Mcl> in {Matrix or denseMatrix + sparseMatrix}
113
114    - Tell users about the possibility to disable the "S4-generic but somewhat slow"
115      cbind/rbind, e.g. via
116
118              function(...) methods:::bind_activation(FALSE))
119
120    - ensure that  M[0], M[FALSE], M[1:2]  works as for traditional Matrices
121
122    - make sure  M[FALSE, FALSE]  works for all Matrices
123      {e.g. fails for M <- Diagonal(4)}
124
125    - <sparse> %*% <dense>  {also in crossprod/tcrossprod}  currently always
126      returns <dense>, since --> Csparse_dense_prod --> cholmod_sdmult
127      and that does only return dense.
128      When the sparse matrix is very sparse, i.e. has many rows with only zero
129      entries, it would make much sense to return sparse.
130
131    - sparse-symmetric + diagonal should stay sparse-symmetric
132      (only stays sparse): Matrix(0, 4, 4) + Diagonal(4, 1:4)
133      --> R/diagMatrix.R ('FIXME')
134      but also R/Ops.R  to ensure  sp-sym. + sp-sym. |-> sp-sym.  etc
135
136    - For a square sparse matrix 'b' {typically dgCMatrix or dgTMatrix},
137      we'd want a function  "Mat_plus_t_Mat" <- function(b) {....}
138      which computes the symmetric sparse matrix   b + t(b)
139      in way that never works with size-doubled vectors from  b@i etc..
140
141    - ! <symmetricMatrix>  loses symmetry, both for dense and sparse matrices.
142      !M  where M is "sparseMatrix", currently always gives dense. This only
143      makes sense when M is ``really sparse''.
144
145    - column names of sparse matrices are not printed;
146      we now "mention" them (if they are non-empty).
147      Option:
148            build show( <sparseMatrix>) on a function, possibly
149            print.sparseMatrix(), which gets an argument such as
150            'col.names.show  = FALSE' which is documented and can be set to TRUE
151
152    - 'arules' needs fast colSums() and rowSums() - for ngCMatrix;
153      do it for "nMatrix" and "lMatrix" and return *integer*

Legend:
 Removed from v.1592 changed lines Added in v.1887

 root@r-forge.r-project.org ViewVC Help Powered by ViewVC 1.0.0
Thanks to: