statsmodels / statsmodels/statsmodels

New version of the Univariate KDE estimator

Open
#1,871 102 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

For my own research, I developed a Univariate KDE module, with a focus on managing boundary conditions. You can find the documentation there:

http://pyqt-fit.readthedocs.org/en/latest/

the package contains more than just the KDE, but I would like to extract the univariate KDE estimator and include it in statsmodels, Of course, I would perform the necessary renaming and any other structural change that would be deemed necessary for inclusion in statsmodels.

Compared to the statsmodels implementation, I decomposed the KDE evaluation in 4 parts for improved modularity:

  • the main KDE object (to provide a uniform API)
  • the kernel object
  • the bandwidth calculation
  • the KDE estimation method

I believe this separation is important to be able to test new methods or kernels. You can follow the tutorial to see how the various parts interact (although I don't talk much about the kernel).

All the modules have documentations and the testing coverage is about 97%, and I believe the structure should provide sufficient flexibility for anyone to implement their own algorithms, either for bandwidth, kernel or for the method itself.

Please, tell me what you think about it,

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.

Research direction

Start by reading the pyqt-fit documentation at http://pyqt-fit.readthedocs.org/en/latest/ and comparing its Univariate KDE module with the existing statsmodels implementation. Review the proposed separation into KDE, kernel, bandwidth, and estimation components, along with the reported tests and coverage. Done means agreeing on an inclusion and structural-change plan before implementation.

Written by the indexing model from the issue text.

Assessment

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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.