Detailed description |
#throws no error with small dimensions, works fine
Matrix::sparseMatrix(i = c(1,1,2), j = c(2,3,3), x = 1:3, dims = c(3,3), dimnames = list(rep(NA, 3), rep(NA, 3)))
#throws an error:
Matrix::sparseMatrix(i = c(1,1,2), j = c(2,3,3), x = 1:3, dims = c(100, 100), dimnames = list(rep(NA, 100), rep(NA, 100)))
#OUTPUT:
# 100 x 100 sparse Matrix of class "dgCMatrix"
# Error in if (msg.if.not.empty && is.list(dn) && length(dn) >= 2 &&
# is.character(cn <- dn[[2]]) && :
# missing value where TRUE/FALSE needed
My guess is that the format() method throws the error, since we do get the description of the object: '100 x 100 sparse Matrix of class "dgCMatrix"' |
|