statsmodels-statistical-modeling

Installation
SKILL.md

statsmodels

Overview

Statsmodels provides classical statistical modeling with rigorous inference for Python. It covers linear models, generalized linear models, discrete choice, time series, and comprehensive diagnostics. Unlike scikit-learn (prediction-focused), statsmodels emphasizes coefficient interpretation, p-values, confidence intervals, and model diagnostics.

When to Use

  • Fitting linear regression (OLS, WLS, GLS) with detailed coefficient tables and diagnostics
  • Running logistic regression with odds ratios and marginal effects for clinical/epidemiological studies
  • Analyzing count data with Poisson or negative binomial regression
  • Time series forecasting with ARIMA, SARIMAX, or exponential smoothing
  • Performing ANOVA, t-tests, or non-parametric tests with proper corrections
  • Testing model assumptions (heteroskedasticity, autocorrelation, normality of residuals)
  • Model comparison using AIC/BIC or likelihood ratio tests
  • Using R-style formula interface (y ~ x1 + x2 + C(group)) for intuitive model specification
  • For prediction-focused ML with cross-validation and hyperparameter tuning, use scikit-learn instead
  • For Bayesian modeling with posterior inference, use pymc instead
Related skills

More from jaechang-hits/sciagent-skills

Installs
9
GitHub Stars
152
First Seen
Mar 16, 2026