From 001f5d62f003782b3ccba3fff69ea8f57fa32340 Mon Sep 17 00:00:00 2001 From: "Julio A. Peraza" <52050407+JulioAPeraza@users.noreply.github.com> Date: Wed, 10 Aug 2022 09:00:32 -0400 Subject: [PATCH] Use 1D array in `scipy.optimize.minimize` (#111) --- pymare/stats.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pymare/stats.py b/pymare/stats.py index 5775c5a..83cdd69 100644 --- a/pymare/stats.py +++ b/pymare/stats.py @@ -109,7 +109,7 @@ def q_profile(y, v, X, alpha=0.05): ub_start = 2 * DerSimonianLaird().fit(y, v, X).params_["tau2"] lb = minimize(lambda x: (q_gen(*args, x) - l_crit) ** 2, [0], bounds=bds).x[0] - ub = minimize(lambda x: (q_gen(*args, x) - u_crit) ** 2, [ub_start], bounds=bds).x[0] + ub = minimize(lambda x: (q_gen(*args, x) - u_crit) ** 2, ub_start, bounds=bds).x[0] return {"ci_l": lb, "ci_u": ub}