MatrixExtra: MatrixExtra package

MatrixExtraR Documentation

MatrixExtra package

Description

Additional methods for the sparse matrices and sparse vector classes from the 'Matrix' package, with an emphasis on the CSR (compressed sparse row) format (a.k.a. "RsparseMatrix" in 'Matrix' parlance).

This package provides, among others:

  • Fast and multi-threaded matrix multiplications for various combinations of '<sparse,dense>' and '<dense,sparse>' types (see matmult), including the dense 'float32' types from the 'float' package (see float-package).

  • Operations that work efficiently in the CSR format, such as concatenating by rows (see rbind2-method) or selecting rows (see slice).

  • Convenience conversion functions for the different sparse matrix types (see conversions).

  • Overloaded operators such as "+" or "*" for many combinations of '<RsparseMatrix,RsparseMatrix>', '<RsparseMatrix,TsparseMatrix>', '<RsparseMatrix,matrix>', and '<RsparseMatrix,scalar>' (see operators).

  • Overloaded mathematical functions that work only on the non-zero entries of matrices (see mathematical-functions).

  • Fast transposes which change the storage format (see t_shallow).

  • Utility functions for sparse matrices (see e.g. sort_sparse_indices and remove_sparse_zeros).

  • Faster replacements for many methods from 'Matrix' for all the sparse formats (COO, CSR, CSC), such as '[' (slice), addition ('+'), elementwise multiplication ('*'), among others (see operators).

  • Convenience functions for sparse objects, such as mapSparse, emptySparse, and a shorter show method for sparse objects.

Important: 'MatrixExtra' modifies some important behaviors from the 'Matrix' library, which might cause some functions from 'Matrix' or other packages to stop working under the default options of 'MatrixExtra'. See MatrixExtra-options for details.

Author(s)

Maintainer: David Cortes david.cortes.rivera@gmail.com [copyright holder]

Other contributors:

  • Dmitry Selivanov [copyright holder]

  • Thibaut Goetghebuer-Planchon (Copyright holder of included robinmap library) [copyright holder]

  • Martin Maechler (Copyright holder of 'Matrix' package from which some code was taken) [copyright holder]

  • Robert Gentleman (Copyright holder of mathematical functions used by base R which were copied) [copyright holder]

  • Ross Ihaka (Copyright holder of mathematical functions used by base R which were copied) [copyright holder]

See Also

Useful links:


MatrixExtra documentation built on May 29, 2024, 2:53 a.m.