/** * Row-copies the given matrix to this sparse implementation. * * @param mat the matrix to copy. */ public SparseDoubleRowMatrix(DoubleMatrix mat) { this(mat.getRowCount(), mat.getColumnCount()); for (int i = 0; i < numColumns; i++) { setRowVector(i, mat.getRowVector(i)); } }