Skip to content

Commit a00526e

Browse files
committed
precommit
1 parent 880dadc commit a00526e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

examples/case_studies/hierarchical_partial_pooling.ipynb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,12 @@
5555
}
5656
],
5757
"source": [
58+
"import aesara.tensor as at\n",
5859
"import arviz as az\n",
5960
"import matplotlib.pyplot as plt\n",
6061
"import numpy as np\n",
6162
"import pandas as pd\n",
6263
"import pymc3 as pm\n",
63-
"import aesara.tensor as at\n",
6464
"\n",
6565
"%matplotlib inline"
6666
]
@@ -127,7 +127,7 @@
127127
"N = len(hits)\n",
128128
"player_names = data.apply(lambda x: x.FirstName + \" \" + x.LastName, axis=1)\n",
129129
"coords = {\"player_names\": player_names.tolist()}\n",
130-
" \n",
130+
"\n",
131131
"with pm.Model(coords=coords) as baseball_model:\n",
132132
"\n",
133133
" phi = pm.Uniform(\"phi\", lower=0.0, upper=1.0)\n",
@@ -223,7 +223,7 @@
223223
],
224224
"source": [
225225
"with baseball_model:\n",
226-
" trace = pm.sample(2000, tune=2000,chains=2, target_accept=0.95, return_inferencedata=True)\n",
226+
" trace = pm.sample(2000, tune=2000, chains=2, target_accept=0.95, return_inferencedata=True)\n",
227227
"\n",
228228
" # check convergence diagnostics\n",
229229
" assert all(az.rhat(trace) < 1.03)"
@@ -292,7 +292,7 @@
292292
}
293293
],
294294
"source": [
295-
"az.plot_forest(trace,var_names=[\"thetas\"]);"
295+
"az.plot_forest(trace, var_names=[\"thetas\"]);"
296296
]
297297
},
298298
{

0 commit comments

Comments
 (0)