See comments on 283e156.
To replace mlm.R:101-102's use of model.matrix with SparseMMFromMatrix, which currently lives in the clusters branch of RItools.
The following code almost works, though nt or nc will have the wrong length if the optmatch object is manually manipulated (e.g. this test). I believe there's a bug in either SparseMMFromMatrix or something with matrix.csr ops, which I will crosspost to RItools about.
sparseMM <- SparseMMFromFactor(theMatch)
nt.csr <- t(as.matrix.csr(z))%*%sparseMM
nt <- attr(nt.csr, "ra")[order(attr(nt.csr, "ja"))]
nc.csr <- t(as.matrix.csr(!z))%*%sparseMM
nc <- attr(nc.csr, "ra")[order(attr(nc.csr, "ja"))]
See comments on 283e156.
To replace mlm.R:101-102's use of
model.matrixwithSparseMMFromMatrix, which currently lives in the clusters branch of RItools.The following code almost works, though
ntorncwill have the wrong length if the optmatch object is manually manipulated (e.g. this test). I believe there's a bug in eitherSparseMMFromMatrixor something withmatrix.csrops, which I will crosspost to RItools about.