better / convoys

Implementation of statistical models to analyze time lagged conversions
https://better.engineering/convoys/
MIT License
260 stars 42 forks source link

Example dos does not work #134

Open jacopotagliabue opened 2 years ago

jacopotagliabue commented 2 years ago

Steps to reproduce:

Stacktrace:

File "examples/dob_violations.py", line 50, in run() File "examples/dob_violations.py", line 25, in run convoys.plotting.plot_cohorts(G, B, T, model=model, ci=0.95, File "/Users/jacopotagliabue/Documents/repos/convoys/venv/lib/python3.8/site-packages/convoys/plotting.py", line 62, in plot_cohorts m.fit(G, B, T) File "/Users/jacopotagliabue/Documents/repos/convoys/venv/lib/python3.8/site-packages/convoys/multi.py", line 31, in fit self.basemodel.fit(X, B, T) File "/Users/jacopotagliabue/Documents/repos/convoys/venv/lib/python3.8/site-packages/convoys/regression.py", line 269, in fit for i, in enumerate(sampler.sample(p0, iterations=n_iterations)): File "/Users/jacopotagliabue/Documents/repos/convoys/venv/lib/python3.8/site-packages/emcee/ensemble.py", line 379, in sample self.backend.grow(iterations, state.blobs) File "/Users/jacopotagliabue/Documents/repos/convoys/venv/lib/python3.8/site-packages/emcee/backends/backend.py", line 175, in grow a = np.empty((i, self.nwalkers, self.ndim), dtype=self.dtype) TypeError: 'numpy.float64' object cannot be interpreted as an integer