With a slope function, the check is one subtraction.
In the editor, finish pre_trend_gap(y, treated, week, start_week) with ls_slope.
Instructions
1
Finish pre_trend_gap(y, treated, week, start_week), using ls_slope from the step before. Use only the weeks before start_week. Return the slope of the treated group's weekly means minus the slope of the control group's.