Sample Selection Models
Overview
In order to facilitate the adjustment of the sample selection models existing in the literature, we created the 'ssmodels' package. Our package allows the adjustment of the classic Heckman model (Heckman (1976), Heckman (1979) doi:10.2307/1912352), and the estimation of the parameters of this model via the maximum likelihood method and two-step method, in addition to the adjustment of the Heckman-t models introduced in the literature by Marchenko and Genton (2012) doi:10.1080/01621459.2012.656011 and the Heckman-Skew model introduced in the literature by Ogundimu and Hutton (2016) doi:10.1111/sjos.12171. We also implemented functions to adjust the generalized version of the Heckman model, introduced by Bastos, Barreto-Souza, and Genton (2021) doi:10.5705/ss.202021.0068, that allows the inclusion of covariables to the dispersion and correlation parameters, and a function to adjust the Heckman-BS model introduced by Bastos and Barreto-Souza (2020) doi:10.1080/02664763.2020.1780570 that uses the Birnbaum-Saunders distribution as a joint distribution of the selection and primary regression variables. This package extends and complements existing R packages such as 'sampleSelection' (Toomet and Henningsen, 2008) and 'ssmrob' (Zhelonkin et al., 2016), providing additional robust and flexible sample selection models.
Bug Fixes
- Corrected the
HeckmanBS()score and standard-error chain rule forrho_star -> rho. - Added
coefficients_linkandgradient_linktoHeckmanBS()results for transparent gradient validation on the optimization scale. - Moved gradient validation scripts and independent score/log-likelihood helpers to
inst/validation/. - Cleaned stale dependency declarations and made
complete.cases()references namespace-explicit.
From NEWS.md in the release
Install
Health
- OK13 OK2026-08-04
- NOTE12 OK, 1 NOTE2026-08-01
- OK14 OK2026-03-10
Documentation
- Help pages
- 22 (2 internal)includes a package overview page
- Examples that run
- 100%10 run in a plain check
- Exported functions with examples
- 31%
- Documented parameters
- 84%
- Return-value docs
- 100%
- Help pages citing references
- 41% with a bibliography file
Downloads
Repository
- PRs merged (all time)
- 100%
- Median days to close, 50 most recently updated closed issues
- not measured
- Median days to close, 50 most recently updated closed PRs
- 0
Stars over time
Forks over time
Issues over time
Commits over time
10 development-tooling and community-health practices detected across 5 families in the upstream repository
Checks run against github.com/fsbmat-ufv/ssmodels on 2026-10-18.
The R CMD check workflow runs on Linux
GitHub Pages site last deployed 2026-09-28 · The repository has a site deploy workflow
pkgdown site last built 2026-09-28
Show all practicesHide 1 practice
Dependencies
Code & Tests
Datasets
People & History
Pick two releases to compare their code metrics.
- 2.0.2Latest2026-05-30 · current release · diff ↗ ·
added 5 exports
summary.HeckmanBS, summary.HeckmanCL, summary.HeckmanGe, summary.HeckmanSK, summary.HeckmantS - RR 4.6.0 released · 2026-04-24
- 2.0.12025-06-02 · diff ↗
- 2.0.02025-06-02 · diff ↗ ·
removed 5 exports
summary.HeckmanBS, summary.HeckmanCL, summary.HeckmanGe, summary.HeckmanSK, summary.HeckmantSadded 2 exports
extract_model_components, postprocess_theta - RR 4.5.0 released · 2025-04-11
- RR 4.4.0 released · 2024-04-24
- RR 4.3.0 released · 2023-04-21
- 1.0.12022-10-04
- RR 4.2.0 released · 2022-04-22
Package metadata
- First published
- 2022-10-04
- Total releases
- 4 / 4 yrs
- License
- GPL (>= 2) OSI
- Minimum R
- ≥ 3.6.0
- Bundled data
- 750 KB / 5 files
- Download size
- 859 KB
Cite
Cite this package
Run in R for the authors' preferred citation:
citation("ssmodels")This package has no citation file, so citation() returns this entry built from DESCRIPTION.
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-22, which the citation names so these numbers can be found later. More on citing and the projects behind them.