statsmodels

Fit OLS, GLM, logistic, and time-series models with statsmodels.

3|Updated Mar 11, 2026
One-click install
npx skills add https://github.com/JunMA98/Computer-science-claude-skills --skill statsmodels-junma98
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: statsmodels
Source: https://github.com/JunMA98/Computer-science-claude-skills/tree/main/skills/statsmodels
Command: npx skills add https://github.com/JunMA98/Computer-science-claude-skills --skill statsmodels-junma98

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Solves the need for rigorous statistical modeling and inference by providing tools to fit OLS, GLM, logistic, Poisson/NegBinomial, mixed models, and time-series analyses with detailed coefficient tables, residual checks, and interpretable summaries.

Core Features & Use Cases

  • OLS, GLM, MixedLM, logistic regression, Poisson/Negative Binomial, and time-series models for diverse data.
  • Diagnostics and model assessment: residuals, AIC/BIC, pseudo R², confidence intervals, and diagnostic plots.
  • Formula API and reproducible workflows with Pandas data frames for CS experiments, telemetry, and research code.

Quick Start

Start with a simple OLS example on your dataset and review the model summary for coefficients and diagnostics.

Frequently Asked Questions about statsmodels

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I fit a GLM or OLS model and get p-values for my telemetry data?

You fit OLS or GLM models to your Pandas DataFrame using a formula API to produce interpretable coefficients, standard errors, p-values, and confidence intervals. This workflow requires Python with the statsmodels package.

What statistical diagnostics are available for time-series and logistic regression?

Statistical diagnostics include residuals, AIC/BIC, pseudo R², confidence intervals, and diagnostic plots. These model assessments validate logistic regression, time-series, and mixed model fits on structured evaluation workflows.

Can I use Python and statsmodels for Poisson and Negative Binomial count models?

Yes, Python with statsmodels supports Poisson and Negative Binomial count models. The process outputs detailed coefficient tables, interpretable summaries, and model assessment metrics like AIC/BIC for analyzing count data.

Do I need Pandas and numpy to run statistical inference on CS experiments?

Yes, fitting statistical inference models on CS experiments requires Python with numpy and pandas. The workflow uses Pandas DataFrames as input to fit models like OLS, GLM, and MixedLM, generating coefficients and diagnostic summaries.

When should I use generalized linear mixed models for my research data?

Use generalized linear mixed models when research data has complex grouped or hierarchical structures. Fitting MixedLM produces interpretable coefficients and detailed diagnostics, handling nested data variations better than standard GLM.

What is the best way to assess model fit and residuals for inference workflows?

The best way to assess inference model fit is by reviewing residual checks, AIC/BIC scores, pseudo R², and confidence intervals. These diagnostics evaluate model quality alongside interpretable coefficient summaries.