Baike.dev
All toolsOnline toolsAI codingTrendingOpen sourceNewsSubmit
Log in
< Back to tools
C

collapse

> 数据库
Open source

Advanced and Fast Data Transformation in R

705 stars0 likes3 views
WebsiteGitHub

About

Advanced and Fast Data Transformation in R

collapse

collapse is a large C/C++-based package for data transformation and statistical computing in R. It aims to:

  • Facilitate complex data transformation, exploration and computing tasks in R.
  • Help make R code fast, flexible, parsimonious and programmer friendly.

Its novel class-agnostic architecture supports all basic R objects and their popular extensions, including units, integer64, xts/zoo, tibble, grouped_df, data.table, sf, pseries and pdata.frame.

Key Features:

  • Advanced statistical programming: A full set of fast statistical functions supporting grouped and weighted computations on vectors, matrices and data frames. Fast and programmable grouping, ordering, matching, deduplication, factor generation and interactions.

  • Fast data manipulation: Fast and flexible functions for data manipulation, data object conversions and memory efficient R programming.

  • Advanced aggregation: Fast and easy multi-type, weighted and parallelized data aggregation.

  • Advanced transformations: Fast row/column arithmetic, (grouped) sweeping out of statistics (by reference), (grouped, weighted) scaling and (higher-dimensional) centering and averaging.

  • Advanced time-computations: Fast and flexible indexed time series and panel data classes, lags/leads, differences and (compound) growth rates on (irregular) time series and panels, panel-autocorrelation functions and panel data to array conversions.

  • List processing: Recursive list search, filtering, splitting, apply and unlisting to data frame.

  • Advanced data exploration: Fast (grouped, weighted, multi-level) descriptive statistical tools.

collapse is written in C and C++, with algorithms much faster than base R's, has extremely low evaluation overheads, scales well (benchmarks: linux | windows), and excels on complex statistical tasks.

Installation

…

Documentation

collapse installs with a built-in structured documentation, implemented via a set of separate help pages. Calling help('collapse-documentation') brings up the the top-level documentation page, providing an overview of the entire package and links to all other documentation pages.

In addition there are several vignettes, among them one on Documentation and Resources.

Cheatsheet

JSS Article

The collapse article is published in the Journal of Statistical Software (volume 116, issue 1). It is the primary reference for academic use of the package and a concise introduction to its design and capabilities.

Presentations

  • useR 2022: Video Recording | Slides
  • BPLIM Workshop 2025: Video Recording | Slides

Example Usage

This provides a simple set of examples introducing some important features of collapse. It should be easy to follow for readers familiar with R.

Click here to expand

…

@article{krantz2026collapse, title = {{collapse}: Advanced and Fast Statistical Computing and Data Transformation in {R}}, author = {Sebastian Krantz}, journal = {Journal of Statistical Software}, year = {2026}, volume = {116}, number = {1}, pages = {1--38}, doi = {10.18637/jss.v116.i01}, }


For a full proper citation also cite the current R package version using `citation("collapse")`.

Issues· 0 open

View all issuesOpen on GitHub

No open issues yet, or sync has not completed.

> Tags

Ccrandata-aggregationdata-analysisdata-manipulation

No comments yet. Be the first to share.

> Details

PublishedAug 1, 2026
UpdatedSep 17, 2026
Category数据库
PricingOpen source

> Related tools

P
PostgreSQL
功能强大的开源关系型数据库
R
Redis
内存数据结构存储,常用作缓存与队列
M
MySQL
广泛使用的开源关系型数据库