We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 67d696e commit 082d4d5Copy full SHA for 082d4d5
causalpy/pymc_models.py
@@ -1030,15 +1030,15 @@ def _data_setter(self, X) -> None:
1030
This method is used internally to register new data for the model for
1031
prediction.
1032
"""
1033
- new_no_of_observations = X.shape[0]
+ n_obs = X.shape[0]
1034
with self:
1035
pm.set_data(
1036
{
1037
"X": X,
1038
- "t": np.arange(len(X)),
1039
- "y": np.zeros(new_no_of_observations),
+ "t": np.arange(n_obs)[:, None],
+ "y": np.zeros(n_obs, 1),
1040
},
1041
- coords={"obs_ind": np.arange(new_no_of_observations)},
+ coords={"obs_ind": np.arange(n_obs)},
1042
)
1043
1044
def score(self, X, y) -> pd.Series:
0 commit comments