Skip to content

Commit 67d550d

Browse files
committed
Add explanation about np.ones
1 parent e290244 commit 67d550d

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

causalpy/data/simulate_data.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,9 @@ def generate_time_series_data(
147147
for var in ["deaths_actual", "temperature"]:
148148
df[var] += norm(0, 0.1).rvs(N)
149149

150-
# add intercept
150+
# add intercept column of ones (for modeling purposes)
151+
# This is correctly a column of ones, not beta_intercept, as beta_intercept
152+
# is already incorporated in the data generation above
151153
df["intercept"] = np.ones(df.shape[0])
152154

153155
return df

0 commit comments

Comments
 (0)