Entropy-Based Segregation Indices
Overview
Computes segregation indices, including the Index of Dissimilarity, as well as the information-theoretic indices developed by Theil (1971) <isbn:978-0471858454>, namely the Mutual Information Index (M) and Theil's Information Index (H). The M, further described by Mora and Ruiz-Castillo (2011) doi:10.1111/j.1467-9531.2011.01237.x and Frankel and Volij (2011) doi:10.1016/j.jet.2010.10.008, is a measure of segregation that is highly decomposable. The package provides tools to decompose the index by units and groups (local segregation), and by within and between terms. The package also provides a method to decompose differences in segregation as described by Elbers (2021) doi:10.1177/0049124121986204. The package includes standard error estimation by bootstrapping, which also corrects for small sample bias. The package also contains functions for visualizing segregation patterns.
- various improvements to compression algorithm
- add dendrogram visualization
- allow multiple curves in
segcurvefunction - segplot: add optional 'secondary_plot' argument
- segplot: remove 'title' argument
- segplot: add optional 'hline' argument
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-04
- NOTE12 OK, 1 NOTE2026-08-01
- OK14 OK2026-04-22
- ERROR13 OK, 1 ERROR2026-04-18
- OK14 OK2026-04-10
Show 2 earlier changesHide 2 earlier changes
- ERROR13 OK, 1 ERROR2026-04-09
- OK14 OK2026-03-10
Documentation
- Help pages
- 23 (1 internal)includes a package overview page
- Examples that run
- 64%7 run in a plain check · 4 never run
- Exported functions with examples
- 58%
- Documented parameters
- 100%
- Return-value docs
- 100%
- Help pages citing references
- 26%
Downloads
Repository
- PRs merged (all time)
- 100%
- Median days to close, 50 most recently updated closed issues
- 2
- Median days to close, 50 most recently updated closed PRs
- 0
Stars over time
Forks over time
Releases over time
Issues over time
PRs over time
10 development-tooling and community-health practices detected across 6 families in the upstream repository
Checks run against github.com/elbersb/segregation on 2026-10-18.
The R CMD check workflow runs on Linux, macOS and Windows, and on R-devel
GitHub Pages site last deployed 2025-12-12 · The repository has a site deploy workflow
Show all practicesHide 2 practices
Dependencies
Installing segregation adds 5 packages (4 with compiled code, 7.8 MB of source tarballs). Heaviest: data.table 5.7 MB, Rcpp 1.8 MB, checkmate 247 KB.
Code & Tests
Datasets
People & History
Pick two releases to compare their code metrics.
- RR 4.6.0 released · 2026-04-24
- RR 4.5.0 released · 2025-04-11
- RR 4.4.0 released · 2024-04-24
- 1.1.0Latest
- 1.0.02023-08-25 · diff ↗ ·
added 10 exports
compress, dissimilarity_expected, exposure, get_crosswalk, isolation, merge_units, mutual_total_nested, scree_plot, segcurve, segplot - RR 4.3.0 released · 2023-04-21
- RR 4.2.0 released · 2022-04-22
- 0.6.02021-09-02 · diff ↗
- RR 4.1.0 released · 2021-05-18
- 0.5.0
- 0.4.0
- RR 4.0.0 released · 2020-04-24
- 0.3.02019-09-20 · diff ↗
- RR 3.6.0 released · 2019-04-26
- 0.2.02019-01-14 · diff ↗
- 0.1.0
Show 3 earlier eventsHide 3 earlier events
- RR 3.5.0 released · 2018-04-23
- 0.0.12018-04-17
- RR 3.4.0 released · 2017-04-21
Package metadata
- First published
- 2018-04-17
- Total releases
- 9 / 8 yrs
- License
- MIT + file LICENSE OSI
- Minimum R
- ≥ 3.5.0
- Bundled data
- 63 KB / 3 files
- Download size
- 501 KB
Cite
Cite this package
Run in R for the authors' entry:
citation("segregation")The package provides a citation file, so citation() returns the authors' own entry.
It points to 10.1177/0049124121986204.
The repository also keeps a CITATION.cff.
Cite the R Observatory
For a number measured here: a download total, a coverage figure, an archival date.
From data release v2026-10-20, which the citation names so these numbers can be found later. More on citing and the projects behind them.