deepcopy_sparse_object {MatrixExtra}R Documentation

Deep copy sparse matrices and vectors

Description

Generates a deep copy of a sparse matrix or sparse vector object, which can come useful when the matrix is to later be passed to functions that will potentially modify it in-place, such as sort_sparse_indices.

Usage

deepcopy_sparse_object(X)

Arguments

X

A sparse matrix or sparse vector from the 'Matrix' package.

Value

The same input 'X' with the fields replaced with deep copies.


[Package MatrixExtra version 0.1.15 Index]