ENH: score confidence interval for GLM, discrete

Open
#2,722 6 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
30/100
Issue type
Feature
Clarity
Needs clarification
Activity status
Stale
Tech stack
python
Domain
data

Research direction

No files or tests are named. Start by reviewing the existing profile-likelihood confidence-interval work and the GLM/discrete score-test implementation, then compare the approach with the referenced two-sample proportion methods. Done should include score confidence intervals for GLM and discrete models, including the stated robust-covariance use case.

Written by the indexing model from the issue text.

Description

comp-discrete comp-genmod Performance type-enh

score tests are doing quite well overall, score confidence intervals are emphasized in some of the two sample proportion comparisons and are doing also reasonably well for medium sample sizes.

Calculation: see references on two sample proportions.
Essentially we are calculating two one-sided score-tests and search for the Null hypothesis parameter.
In terms of implementation and effort required this should be similar to profile likelihood confidence intervals. An efficient implementation might be able to use the offset and doesn't need to change exog in each case, if we want the confidence interval for a single parameter. (I guess changing the constant for affine restrictions would work in the constrained transformed model, but requires adjusting the constraints transformation but not of the exog, AFAICguess.)

The advantage of score confidence intervals should be that we can use robust covariance matrices to handle overdispersion or heteroscedasticity or correlation.
example http://www.inside-r.org/packages/cran/pairwiseCI/docs/pairwiseCImethodsCount
the mention dispersion problems with profile confidence interval that are handled for the specific proportional overdispersion case by QuasiPoisson (using deviance profile which I never heard but is just scaled loglikelihood, I guess).

Dominant language
Python
Stars
11.6k
Forks
3.6k
Avg merge
7h 37m
Merged PRs (30d)
96

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from statsmodels/statsmodels

All issues in statsmodels/statsmodels

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.