Skip to content

Commit 1e28074

Browse files
committed
1st ed final commit
1 parent 32d182d commit 1e28074

File tree

2 files changed

+4
-21
lines changed

2 files changed

+4
-21
lines changed

econmt-regression.ipynb

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -901,26 +901,10 @@
901901
"metadata": {},
902902
"outputs": [],
903903
"source": [
904-
"results_cigs_ols = feols(\"np.log(packs) ~ np.log(rincome) + np.log(rprice) | year + state\", data=dfiv, vcov={\"CRV1\": \"year\"})\n",
904+
"results_cigs_ols = feols(\"np.log(packs) ~ np.log(rprice) + np.log(rincome) | year + state\", data=dfiv, vcov={\"CRV1\": \"year\"})\n",
905905
"results_cigs_ols.summary()"
906906
]
907907
},
908-
{
909-
"cell_type": "markdown",
910-
"metadata": {},
911-
"source": [
912-
"Now select these two models to compare:"
913-
]
914-
},
915-
{
916-
"cell_type": "code",
917-
"execution_count": null,
918-
"metadata": {},
919-
"outputs": [],
920-
"source": [
921-
"etable([results_iv, results_cigs_ols], type=\"md\")"
922-
]
923-
},
924908
{
925909
"cell_type": "markdown",
926910
"metadata": {},

econmt-statistics.ipynb

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,6 @@
287287
"source": [
288288
"import scipy.stats as st\n",
289289
"\n",
290-
"\n",
291290
"def plot_t_stat(x, mu):\n",
292291
" T = np.linspace(-7, 7, 500)\n",
293292
" pdf_vals = st.t.pdf(T, len(x) - 1)\n",
@@ -304,14 +303,14 @@
304303
" fig, ax = plt.subplots()\n",
305304
" ax.plot(T, pdf_vals, label=f\"Student t: dof={len(x)-1}\", zorder=2)\n",
306305
" ax.fill_between(\n",
307-
" interval_T, 0, interval_y, alpha=0.2, label=r\"95% interval\", zorder=1\n",
306+
" interval_T, 0, interval_y, alpha=0.2, label=\"95% interval\", zorder=1\n",
308307
" )\n",
309308
" ax.plot(\n",
310309
" actual_T_stat,\n",
311310
" st.t.pdf(actual_T_stat, len(x) - 1),\n",
312311
" \"bo\",\n",
313312
" ms=15,\n",
314-
" label=r\"$\\sqrt{n}(\\bar{x} - \\mu)/\\hat{\\sigma}}$\",\n",
313+
" label=r\"$\\sqrt{n} (\\bar{x} - \\mu) / \\hat{\\sigma}$\",\n",
315314
" color=\"orchid\",\n",
316315
" zorder=4,\n",
317316
" )\n",
@@ -859,7 +858,7 @@
859858
"name": "python",
860859
"nbconvert_exporter": "python",
861860
"pygments_lexer": "ipython3",
862-
"version": "3.10.12"
861+
"version": "3.10.13"
863862
},
864863
"vscode": {
865864
"interpreter": {

0 commit comments

Comments
 (0)