Skip to content

Commit feaf199

Browse files
authored
Merge pull request #182 from igerber/fix/tutorial-dollar-sign-escape
Fix dollar sign escaping in continuous DiD tutorial
2 parents c832f1e + 3968b59 commit feaf199

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

docs/tutorials/14_continuous_did.ipynb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@
105105
"source": [
106106
"## 2. Data Setup\n",
107107
"\n",
108-
"We generate a balanced panel of workers. Some are assigned to a training cohort (treated in period 2), while 30% are never treated. Each trained worker receives a dose (hours) drawn from a log-normal distribution. The true treatment effect is **ATT(d) = 1 + 2d** — each hour of training adds \\$2 to earnings, plus a base effect of \\$1 for any training at all."
108+
"We generate a balanced panel of workers. Some are assigned to a training cohort (treated in period 2), while 30% are never treated. Each trained worker receives a dose (hours) drawn from a log-normal distribution. The true treatment effect is **ATT(d) = 1 + 2d** — each hour of training adds \\\\$2 to earnings, plus a base effect of \\\\$1 for any training at all."
109109
]
110110
},
111111
{
@@ -301,8 +301,8 @@
301301
"source": [
302302
"### Interpreting the dose-response curves\n",
303303
"\n",
304-
"- **Left panel (ATT):** The total effect of training rises roughly linearly with dose, closely tracking the true curve (dashed). A worker with 3 hours of training gains about \\$7 in earnings; a worker with 5 hours gains about \\$11.\n",
305-
"- **Right panel (ACRT):** The marginal return to one additional hour is approximately constant at \\$2, matching the true DGP. The confidence band is wider at extreme doses where fewer workers are observed.\n",
304+
"- **Left panel (ATT):** The total effect of training rises roughly linearly with dose, closely tracking the true curve (dashed). A worker with 3 hours of training gains about \\\\$7 in earnings; a worker with 5 hours gains about \\\\$11.\n",
305+
"- **Right panel (ACRT):** The marginal return to one additional hour is approximately constant at \\\\$2, matching the true DGP. The confidence band is wider at extreme doses where fewer workers are observed.\n",
306306
"\n",
307307
"These curves require the **strong parallel trends** assumption. Under standard PT only, the overall binarized effect is identified — this is ATT_loc (the local average across dose groups). The dose-response curve and ACRT_glob are not identified under standard PT because they involve cross-dose comparisons and counterfactual dose-response derivatives. The ATT_glob reported by the estimator is mechanically the binarized DiD: under standard PT it equals ATT_loc, while under strong PT it additionally equals the global average ATT_glob."
308308
]

0 commit comments

Comments
 (0)