Skip to content

SparseArray

Bioc current

High-performance sparse data representation and manipulation in R

v1.12.2 · software · Artistic-2.0

Release Lineage

Entered 3.17 · Apr 26, 2023

Current · Requires R 4.6

1.0 In 7 of 49 releases 3.23

Description

The SparseArray package provides array-like containers for efficient in-memory representation of multidimensional sparse data in R (arrays and matrices). The package defines the SparseArray virtual class and two concrete subclasses: COO_SparseArray and SVT_SparseArray. Each subclass uses its own internal representation of the nonzero multidimensional data: the "COO layout" and the "SVT layout", respectively. SVT_SparseArray objects mimic as much as possible the behavior of ordinary matrix and array objects in base R. In particular, they suppport most of the "standard matrix and array API" defined in base R and in the matrixStats package from CRAN.

Test coverage

Line coverage

Expression

Tests / Examples

Functions

1069 28 exported

Complexity

2.8 avg / 26 max

Call network

1069 nodes / 1792 edges

Test coverage is not measured for Bioconductor packages; nodes fall back to a neutral fill.

Loading call graph…

Lowest coverage

Per-function coverage is not measured for this package yet.

Code

Structure

Lines of code

39,826

Files

196

Compiled share

52.8%

Has compiled src

Yes

Language breakdown

R 7,927 (19.9%)C/C++/src 21,024 (52.8%)Tests 6,000 (15.1%)Docs 4,375 (11%)Vignettes 500 (1.3%)

API

Exported functions

44

Internal functions

246

Recent export changes

v3.21+1 rowsum.dsparseMatrix  −1 rowsum.dgCMatrix
v3.20+16 aperm.NaArray, as.array.NaArray, mean.SparseArray +13 more  −1 rowsum.SVT_SparseMatrix

Testing & CI

Has tests

Yes

Test-to-code ratio

0.76

testthat edition

CI present

No

CI type

[]

PR gated

No

Docs

Roxygen coverage

100%

Health & Security signals

Informational signals; not verdicts.

on.exit coverage

66.7%

Unsafe pattern score

0

Dep constraint coverage

36.4%

Secret pattern count

0

Bundled 3rd-party code

2 items

Portability & License

Min R version

4.3.0

System requirements

C++ standard

License

Artistic-2.0

License flags

SPDX valid, OSI approved

History

Versions

7

First release

2023-08-30

Latest release

2026-05-01

Avg cadence

156 days

Cold removal rate

100%

Dep drift

1

LOC over versions

v3.17: 23,075 LOCv3.18: 23,327 LOCv3.19: 26,590 LOCv3.20: 38,136 LOCv3.21: 38,362 LOCv3.22: 39,762 LOCv3.23: 39,826 LOC

Per-file churn detail lives in the source pipeline: https://github.com/r-observatory/bioc-code-metrics.

Documentation

Documentation
READMEYes · 64 wordsVignettesYes · dynamicpkgdown siteNoNEWSYes · 33% structuredCode of conductNoContributing guideNo
Examples that run
100%
Documented parameters
94%
Return-value docs
94%
References docs
0%

Topics

Depended on by (31)

CRAN (1)

People

Cite

Cite this package

Run in R for the authors' preferred citation:

citation("SparseArray")
Pagès, H., Carey, V., Irizarry, R. A., & Serizay, J. (2026). SparseArray: High-performance sparse data representation and manipulation in R (Version 1.12.2) [Computer software]. https://bioconductor.org/packages/SparseArray

This is what citation() produces when a package has no citation file of its own. If it prints something else, use that.

Cite the R Observatory

For a number measured here: a download total, a coverage figure, an archival date.

APA

Balamuta, J. J. (2026). R Observatory: Metrics for SparseArray version 1.12.2 [Data set]. HJJB, LLC. Data release v2026-08-23. https://doi.org/10.5281/zenodo.21843040

From data release v2026-08-23, which the citation names so these numbers can be found later. More on citing and the projects behind them.

Report a problem with this page →

Privacy choices

These apply to this browser and are stored on this device only. Nothing about your choice is sent to us.

Read the privacy policy