causalimpact
causalimpact copied to clipboard
TypeError: is_list_like() takes 1 positional argument but 2 were given
I never had this error until recently. When I do impact.run(), I see the following error:
`---------------------------------------------------------------------------
TypeError Traceback (most recent call last)
/opt/anaconda3/envs/ishbooks/lib/python3.6/site-packages/causalimpact/analysis.py in run(self) 107 kwargs["model_args"], 108 kwargs["alpha"], --> 109 self.params["estimation"], 110 ) 111 else:
/opt/anaconda3/envs/ishbooks/lib/python3.6/site-packages/causalimpact/analysis.py in _run_with_data(self, data, pre_period, post_period, model_args, alpha, estimation) 422 if model_args["standardize_data"]: 423 sd_results = standardize_all_variables( --> 424 data_modeling, pre_period, post_period 425 ) 426 df_pre = sd_results["data_pre"]
/opt/anaconda3/envs/ishbooks/lib/python3.6/site-packages/causalimpact/misc.py in standardize_all_variables(data, pre_period, post_period) 17 18 if not ( ---> 19 pd.api.types.is_list_like(pre_period, list) 20 and pd.api.types.is_list_like(post_period) 21 ):
TypeError: is_list_like() takes 1 positional argument but 2 were given`
It looks to me like is_list_like in this instance does not need the second argument, namely "list". Not sure how that suddenly became a problem on my end however.