Skip to content

detectseparation

0.4.0

Detect and Check for Separation and Infinite Maximum Likelihood Estimates

4packages depend
51.3Kdownloads / year
89.3%test coverage
9/13checks pass

Overview

About
Maintained by Ioannis KosmidisFirst published 2020-03-254 releasesCRAN page ↗GitHub ↗

Provides pre-fit and post-fit methods for detecting separation and infinite maximum likelihood estimates in generalized linear models with categorical responses. The pre-fit methods apply on binomial-response generalized liner models such as logit, probit and cloglog regression, and can be directly supplied as fitting methods to the glm() function. They solve the linear programming problems for the detection of separation developed in Konis (2007, https://ora.ox.ac.uk/objects/uuid:8f9ee0d0-d78e-4101-9ab4-f9cbceed2a2a) using 'ROI' https://cran.r-project.org/package=ROI or 'lpSolveAPI' https://cran.r-project.org/package=lpSolveAPI. The post-fit methods apply to models with categorical responses, including binomial-response generalized linear models and multinomial-response models, such as baseline category logits and adjacent category logits models; for example, the models implemented in the 'brglm2' https://cran.r-project.org/package=brglm2 package. The post-fit methods successively refit the model with increasing number of iteratively reweighted least squares iterations, and monitor the ratio of the estimated standard error for each parameter to what it has been in the first iteration. According to the results in Lesaffre & Albert (1989, https://www.jstor.org/stable/2345845), divergence of those ratios indicates data separation.

Install

Health

CRAN checks
4NOTE9OK
Failing flavors
  • NOTE r-devel-linux-x86_64-debian-clang
  • NOTE r-devel-linux-x86_64-debian-gcc
  • NOTE r-devel-linux-x86_64-fedora-gcc
  • NOTE r-devel-windows-x86_64
Slowest check: 1.7 min · r-devel-linux-x86_64-fedora-clang
Code health
Yes
Tests · ratio 0.00
89.3%
Coverage · measured lines
100%
Documentation · exports
4
Dependencies · direct
Check history
  • NOTE2026-07-16
    11 OK · 2 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE
  • OK2026-03-10
    14 OK · 0 NOTE · 0 WARNING · 0 ERROR · 0 FAILURE

Documentation

Documentation
READMEYes · 902 wordsVignettesYes · dynamicpkgdown siteNoNEWSYes · 100% structuredCode of conductNoContributing guideNo
Examples that run
100%
Documented parameters
100%
Return-value docs
50%
References docs
67%

Downloads

51.3K
CRAN downloads in the past year
Rank #1,858 · ~141/day · ~4.3K/mo
Daily download trend is not available in this view yet.
3K30 days
13.9K90 days
51.3K1 year
Compare downloads with other packages →
Also on192 r2u22 autocran1.2K conda_forge

Repository

Repository
7Stars
1Forks
3Open issues
0Open PRs
4Releases
195Commits
5Contributors
195 commits · Last activity 2026-04-29

Stars over time

2025-03-14 · 72026-07-07 · 7

Repository practices

Upstream repositoryBeta

4 development-tooling and community-health practices detected across 4 families in the upstream repository

Checks run against github.com/ikosmidis/detectseparation on 2026-07-19.

Continuous integration (1)
GitHub Actions
Docs source (1)
README.Rmd
Lint, format, editor (1)
RStudio project
Coverage (1)
Codecov
How this is detected·Detection ruleset v1 (2026-07-18)

Dependencies

Declared dependencies
14 external dependencies (excludes base and recommended)
Depends (1)
R >= 3.3.0
LinkingTo (0)
none
Enhances (0)
none
Reverse dependencies
4direct
0indirect

Code & Tests

Code Composition
R 1,231 (49%)Rd 784 (31%)Vignettes 393 (16%)Other 110 (4%)
Code characteristics
Object systems
S34
Cyclomatic complexity
3.0 median / 22 max
Test cases
64 / 0.00 per code line

Test coverage

Line coverage

89%

Expression

87.4%

Tests / Examples

89.3% / 62% ex

Functions

14 4 exported

Complexity

5.3 avg / 22 max

Call network

14 nodes / 4 edges

Loading call graph…

Lowest coverage

14 functions
FunctionCycloCoverage
plot.inf_check10%
print.detect_infinite_estimates30%
check_infinite_estimates.glm669%
.detect_infinite_estimates1492%
print.detect_separation593%
separation_type_ROI393%

Datasets

Bundled datasets · 3
NameClassRows × ColsAlso ships in
endometrialdata.frame79 × 4in 6 packages
lizardsdata.frame23 × 6in 3 packages
silvapulle1981data.frame35 × 2

People & History

People (4)
Maintainer (1)
Author, Maintainer
Authors (3)
Author, Maintainer
Author · added in 0.3
Contributors (1)
Contributor
Package Timeline

4 releases. Pick two to compare their code metrics. R releases are shown for context.

  • R
    R 4.6.0 released · 2026-04-24
  • 0.4.0Latest
    2026-04-19 · current release · diff ↗
  • R
    R 4.5.0 released · 2025-04-11
  • R
    R 4.4.0 released · 2024-04-24
  • R
    R 4.3.0 released · 2023-04-21
  • 0.3
    2022-08-26 · diff ↗
  • R
    R 4.2.0 released · 2022-04-22
  • R
    R 4.1.0 released · 2021-05-18
  • 0.2
    2021-04-22 · diff ↗
  • R
    R 4.0.0 released · 2020-04-24
  • 0.1
    2020-03-25
  • R
    R 3.6.0 released · 2019-04-26

Package metadata

First published
2020-03-25
Total releases
4 / 6 yrs
License
GPL-3 OSI
Minimum R
≥ 3.3.0
Bundled data
1.2 KB / 3 files
Download size
104 KB
Installed size
not tracked yet
With dependencies
not tracked yet
Report a problem with this page →