Skip to content

remove df_summary #2893

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Mar 6, 2018
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions RELEASE-NOTES.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
### Deprecations

- DIC and BPIC calculations have been removed
- df_summary have been removed, use summary instead
- `njobs` and `nchains` kwarg are deprecated in favor of `cores` and `chains` for `sample`
- `lag` kwarg in `pm.stats.autocorr` and `pm.stats.autocov` is deprecated.

Expand Down
158 changes: 91 additions & 67 deletions docs/source/notebooks/BEST.ipynb

Large diffs are not rendered by default.

100 changes: 48 additions & 52 deletions docs/source/notebooks/Bayes_factor.ipynb

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions docs/source/notebooks/GLM-model-selection.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
"name": "stdout",
"output_type": "stream",
"text": [
"Runing on PyMC3 v3.3\n"
"Running on PyMC3 v3.3\n"
]
}
],
Expand All @@ -31,7 +31,7 @@
"from ipywidgets import interactive, fixed\n",
"\n",
"plt.style.use('seaborn-darkgrid')\n",
"print('Runing on PyMC3 v{}'.format(pm.__version__))\n",
"print('Running on PyMC3 v{}'.format(pm.__version__))\n",
"rndst = np.random.RandomState(0)"
]
},
Expand Down
68 changes: 34 additions & 34 deletions docs/source/notebooks/GLM-negative-binomial-regression.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -4,52 +4,50 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"# GLM: Negative Binomial Regression\n",
"\n",
"This notebook demos negative binomial regression using the `glm` submodule. It closely follows the GLM Poisson regression example by [Jonathan Sedar](https://github.com/jonsedar) (which is in turn insipired by [a project by Ian Osvald](http://ianozsvald.com/2016/05/07/statistically-solving-sneezes-and-sniffles-a-work-in-progress-report-at-pydatalondon-2016/)) except the data here is negative binomially distributed instead of Poisson distributed.\n",
"\n",
"Negative binomial regression is used to model count data for which the variance is higher than the mean. The [negative binomial distribution](https://en.wikipedia.org/wiki/Negative_binomial_distribution) can be thought of as a Poisson distribution whose rate parameter is gamma distributed, so that rate parameter can be adjusted to account for the increased variance.\n",
"\n",
"#### Contents\n",
"\n",
"+ [Setup](#Setup)\n",
" + [Convenience Functions](#Convenience-Functions)\n",
" + [Generate Data](#Generate-Data)\n",
" + [Poisson Data](#Poisson-Data)\n",
" + [Negative Binomial Data](#Negative-Binomial-Data)\n",
" + [Visualize the Data](#Visualize-the-Data)\n",
"\n",
"\n",
"+ [Negative Binomial Regression](#Negative-Binomial-Regression)\n",
" + [Create GLM Model](#Create-GLM-Model)\n",
" + [View Results](#View-Results)\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Setup"
"# GLM: Negative Binomial Regression"
]
},
{
"cell_type": "code",
"execution_count": 1,
"metadata": {
"scrolled": true
},
"outputs": [],
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"/home/osvaldo/anaconda3/lib/python3.6/site-packages/h5py/__init__.py:36: FutureWarning: Conversion of the second argument of issubdtype from `float` to `np.floating` is deprecated. In future, it will be treated as `np.float64 == np.dtype(float).type`.\n",
" from ._conv import register_converters as _register_converters\n"
]
},
{
"name": "stdout",
"output_type": "stream",
"text": [
"Running on PyMC3 v3.3\n"
]
}
],
"source": [
"%matplotlib inline\n",
"import numpy as np\n",
"import pandas as pd\n",
"import pymc3 as pm\n",
"from scipy import stats\n",
"from scipy import optimize\n",
"import matplotlib.pyplot as plt\n",
"plt.style.use('seaborn-darkgrid')\n",
"import seaborn as sns\n",
"import re\n",
"print('Running on PyMC3 v{}'.format(pm.__version__))"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"This notebook demos negative binomial regression using the `glm` submodule. It closely follows the GLM Poisson regression example by [Jonathan Sedar](https://github.com/jonsedar) (which is in turn inspired by [a project by Ian Osvald](http://ianozsvald.com/2016/05/07/statistically-solving-sneezes-and-sniffles-a-work-in-progress-report-at-pydatalondon-2016/)) except the data here is negative binomially distributed instead of Poisson distributed.\n",
"\n",
"%matplotlib inline"
"Negative binomial regression is used to model count data for which the variance is higher than the mean. The [negative binomial distribution](https://en.wikipedia.org/wiki/Negative_binomial_distribution) can be thought of as a Poisson distribution whose rate parameter is gamma distributed, so that rate parameter can be adjusted to account for the increased variance."
]
},
{
Expand Down Expand Up @@ -246,7 +244,9 @@
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"metadata": {
"collapsed": true
},
"outputs": [],
"source": [
"# Gamma shape parameter\n",
Expand Down Expand Up @@ -670,7 +670,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.5.2"
"version": "3.6.3"
}
},
"nbformat": 4,
Expand Down
Loading