Skip to main content
Files added late

8 files were added to this release more than 14 days after its initial publication. Inspect the release files before installing.

What it is

Statsmodels is a Python package that provides a complement to scipy for statistical computations including descriptive statistics and estimation and inference for statistical models.

Documentation for the 0.4 version is currently at http://statsmodels.sourceforge.net/devel/

Main Features

  • linear regression models: Generalized least squares (including weighted least squares and least squares with autoregressive errors), ordinary least squares.

  • glm: Generalized linear models with support for all of the one-parameter exponential family distributions.

  • discrete: regression with discrete dependent variables, including Logit, Probit, MNLogit, Poisson, based on maximum likelihood estimators

  • rlm: Robust linear models with support for several M-estimators.

  • tsa: models for time series analysis

    • univariate time series analysis: AR, ARIMA

    • vector autoregressive models, VAR and structural VAR

    • descriptive statistics and process models for time series analysis

  • nonparametric : (Univariate) kernel density estimators

  • datasets: Datasets to be distributed and used for examples and in testing.

  • stats: a wide range of statistical tests

    • diagnostics and specification tests

    • goodness-of-fit and normality tests

    • functions for multiple testing

    • various additional statistical tests

  • iolib

    • Tools for reading Stata .dta files into numpy arrays.

    • printing table output to ascii, latex, and html

  • miscellaneous models

  • sandbox: statsmodels contains a sandbox folder with code in various stages of developement and testing which is not considered “production ready”. This covers among others Mixed (repeated measures) Models, GARCH models, general method of moments (GMM) estimators, kernel regression, various extensions to scipy.stats.distributions, panel data models, generalized additive models and information theoretic measures.

Where to get it

The master branch on GitHub is the most up to date code

https://www.github.com/statsmodels/statsmodels

Source download of release tags are available on GitHub

https://github.com/statsmodels/statsmodels/tags

Binaries and source distributions are available from PyPi

http://pypi.python.org/pypi/statsmodels/

Installation from sources

See INSTALL.txt for requirements or see the documentation

http://statsmodels.sf.net/devel/install.html

License

Modified BSD (3-clause)

Documentation

The official documentation is hosted on SourceForge

http://statsmodels.sf.net/

Windows Help

A htmlhelp file (statsmodels.chm) will be available. This can be opened from the python interpreter

>>> import statsmodels.api as sm
>>> sm.open_help()

Discussion and Development

Discussions take place on our mailing list.

http://groups.google.com/group/pystatsmodels

We are very interested in feedback about usability and suggestions for improvements.

Bug Reports

Bug reports can be submitted to the issue tracker at

https://github.com/statsmodels/statsmodels/issues

Release History

0.4.0

Main Changes and Additions

  • Added pandas dependency.

  • Cython source is built automatically if cython and compiler are present

  • Support use of dates in timeseries models

  • Improved plots - Violin plots - Bean Plots - QQ Plots

  • Added lowess function

  • Support for pandas Series and DataFrame objects. Results instances return pandas objects if the models are fit using pandas objects.

  • Full Python 3 compatibility

  • Fix bugs in genfromdta. Convert Stata .dta format to structured array preserving all types. Conversion is much faster now.

  • Improved documentation

  • Models and results are pickleable via save/load, optionally saving the model data.

  • Kernel Density Estimation now uses Cython and is considerably faster.

  • Diagnostics for outlier and influence statistics in OLS

  • Added El Nino Sea Surface Temperatures dataset

  • Numerous bug fixes

  • Internal code refactoring

  • Improved documentation including examples as part of HTML

Changes that break backwards compatibility

  • Deprecated scikits namespace. The recommended import is now:

    import statsmodels.api as sm
  • model.predict methods signature is now (params, exog, …) where before it assumed that the model had been fit and omitted the params argument.

  • For consistency with other multi-equation models, the parameters of MNLogit are now transposed.

  • tools.tools.ECDF -> distributions.ECDF

  • tools.tools.monotone_fn_inverter -> distributions.monotone_fn_inverter

  • tools.tools.StepFunction -> distributions.StepFunction

0.3.1

  • Removed academic-only WFS dataset.

  • Fix easy_install issue on Windows.

0.3.0

Changes that break backwards compatibility

Added api.py for importing. So the new convention for importing is:

import scikits.statsmodels.api as sm

Importing from modules directly now avoids unnecessary imports and increases the import speed if a library or user only needs specific functions.

  • sandbox/output.py -> iolib/table.py

  • lib/io.py -> iolib/foreign.py (Now contains Stata .dta format reader)

  • family -> families

  • families.links.inverse -> families.links.inverse_power

  • Datasets’ Load class is now load function.

  • regression.py -> regression/linear_model.py

  • discretemod.py -> discrete/discrete_model.py

  • rlm.py -> robust/robust_linear_model.py

  • glm.py -> genmod/generalized_linear_model.py

  • model.py -> base/model.py

  • t() method -> tvalues attribute (t() still exists but raises a warning)

Main changes and additions

  • Numerous bugfixes.

  • Time Series Analysis model (tsa)

    • Vector Autoregression Models VAR (tsa.VAR)

    • Autogressive Models AR (tsa.AR)

    • Autoregressive Moving Average Models ARMA (tsa.ARMA) optionally uses Cython for Kalman Filtering use setup.py install with option –with-cython

    • Baxter-King band-pass filter (tsa.filters.bkfilter)

    • Hodrick-Prescott filter (tsa.filters.hpfilter)

    • Christiano-Fitzgerald filter (tsa.filters.cffilter)

  • Improved maximum likelihood framework uses all available scipy.optimize solvers

  • Refactor of the datasets sub-package.

  • Added more datasets for examples.

  • Removed RPy dependency for running the test suite.

  • Refactored the test suite.

  • Refactored codebase/directory structure.

  • Support for offset and exposure in GLM.

  • Removed data_weights argument to GLM.fit for Binomial models.

  • New statistical tests, especially diagnostic and specification tests

  • Multiple test correction

  • General Method of Moment framework in sandbox

  • Improved documentation

  • and other additions

0.2.0

Main changes

  • renames for more consistency RLM.fitted_values -> RLM.fittedvalues GLMResults.resid_dev -> GLMResults.resid_deviance

  • GLMResults, RegressionResults: lazy calculations, convert attributes to properties with _cache

  • fix tests to run without rpy

  • expanded examples in examples directory

  • add PyDTA to lib.io – functions for reading Stata .dta binary files and converting them to numpy arrays

  • made tools.categorical much more robust

  • add_constant now takes a prepend argument

  • fix GLS to work with only a one column design

New

  • add four new datasets

    • A dataset from the American National Election Studies (1996)

    • Grunfeld (1950) investment data

    • Spector and Mazzeo (1980) program effectiveness data

    • A US macroeconomic dataset

  • add four new Maximum Likelihood Estimators for models with a discrete dependent variables with examples

    • Logit

    • Probit

    • MNLogit (multinomial logit)

    • Poisson

Sandbox

  • add qqplot in sandbox.graphics

  • add sandbox.tsa (time series analysis) and sandbox.regression (anova)

  • add principal component analysis in sandbox.tools

  • add Seemingly Unrelated Regression (SUR) and Two-Stage Least Squares for systems of equations in sandbox.sysreg.Sem2SLS

  • add restricted least squares (RLS)

0.1.0b1

  • initial release

Release files for statsmodels 0.4.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Files added late

8 files were uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release files before installing.

Source distributions (sdists)

Source distribution for statsmodels 0.4.0
File Size Uploaded
statsmodels-0.4.0.zip 4.4 MB Details
statsmodels-0.4.0.tar.gz 4.1 MB Details

Built distributions (wheels)

Table of built distributions (wheels) for statsmodels 0.4.0
File
statsmodels-0.4.0.win-amd64-py3.2.exe Details
statsmodels-0.4.0.win-amd64-py2.7.exe Details
statsmodels-0.4.0.win-amd64-py2.6.exe Details
statsmodels-0.4.0.win32-py3.2.exe Details
statsmodels-0.4.0.win32-py2.7.exe Details
statsmodels-0.4.0.win32-py2.6.exe Details

Total release size: 29.6 MB

Release files / statsmodels-0.4.0.zip

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.zip
Size 4.4 MB
Tags Source
SHA-256 checksum
How to use checksums
527396d220f84d60e50d1a9b91f3dbe364c821a3344fab27bb2ffbc5c766aaec
BLAKE2b-256 checksum
How to use checksums
65966d99d8055dee6aba982775aa577d79db195e26a4ad534482a293440dc95b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.tar.gz

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.tar.gz
Size 4.1 MB
Tags Source
SHA-256 checksum
How to use checksums
b11280a773c4ceb95e8ee4fdf32a8d2e337ab4c303ad134a63b64d62277202e4
BLAKE2b-256 checksum
How to use checksums
76a080cc74654f30eb01a95194c6d486f4ce0dcee268c687d571b8aa7984478f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win-amd64-py3.2.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win-amd64-py3.2.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
099769b68bfe8db6b1e6a416ad6440bf95b3141a7adec22ea895a91af7555b60
BLAKE2b-256 checksum
How to use checksums
a1c62349e2b4a6791a99ae607fba1597be1047cf738e7cbcdb02219d5c4eaedd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win-amd64-py2.7.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win-amd64-py2.7.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
9e77660286a5e5f8e7ed34f955f89586658544da9d406f776304d8413ede869e
BLAKE2b-256 checksum
How to use checksums
d2fcd9a766ad568e16be2311ecb239b035e8b50ee3724b7ebc61391f14941ce1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win-amd64-py2.6.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win-amd64-py2.6.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
d6801dccd57fea4a12a4a8bc8c4f2fdc7c7ee17f5a4ab4d71955515cc41d674e
BLAKE2b-256 checksum
How to use checksums
297b86b65e5d2567b8795d2403ff290dc3dd0dc88e41856509129c418f7a06f1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win32-py3.2.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win32-py3.2.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
b4fb5e78bf3040518cdbd925d078b207d651c1611a4f7d688e3f2cc38050d143
BLAKE2b-256 checksum
How to use checksums
e8a9174b29b14ffedb23c54d9038ed3ee58c4f85e8eb64296e7d1ba0f76597b7
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win32-py2.7.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win32-py2.7.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
387be4a9cb07305df1453f87791b2f9c5faa0778776276f524ca57847e2baaa2
BLAKE2b-256 checksum
How to use checksums
e8da2c5171f41ec68c34845cbb084071fe88441cf6dbc61f95a7156716a7f132
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / statsmodels-0.4.0.win32-py2.6.exe

File added late

This file was uploaded more than 14 days after the first file in this release.

While project maintainers occasionally add legitimate files to an existing release, late additions can also indicate a security compromise.

We recommend inspecting the release file before installing.

Download URL statsmodels-0.4.0.win32-py2.6.exe
Size 3.5 MB
Tags Source
SHA-256 checksum
How to use checksums
0eb716f59ce1a1d7d0a95dca3dae7535f0d9adf324e76655743811c1fcf5ebe9
BLAKE2b-256 checksum
How to use checksums
3ed99d25a99db2a261da2e49cfb6a5ca03310a61310219b28f8612b6fcd582ff
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

0.9.0

22 release files

0.5.0

8 release files

0.4.3

8 release files

0.4.1

8 release files

This release

0.4.0 This release

8 release files

0.4.0rc2

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page