From 3968bf682ee1e33c9bcccd865b93ea444a0a044e Mon Sep 17 00:00:00 2001 From: "Travis A. O'Brien" Date: Fri, 27 Sep 2024 16:09:28 -0400 Subject: [PATCH] Implement the fix proposed by @jackrolph --- src/fastkde/fastKDE.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/fastkde/fastKDE.py b/src/fastkde/fastKDE.py index 32d0125..b44d802 100644 --- a/src/fastkde/fastKDE.py +++ b/src/fastkde/fastKDE.py @@ -1433,15 +1433,10 @@ def underlyingFunction(x,x0=305,y0=200,yrange=4): ) ) - # reorder the variable names so that the conditioning variables are first - var_names = ( - var_names[len(conditioningVars) :] + var_names[: len(conditioningVars)] - ) - # extract the conditioning variable names - conditioning_var_names = var_names[len(conditioningVars) :] + conditioning_var_names = var_names[:len(conditioningVars)] # extract the input variable names - input_var_names = var_names[: len(conditioningVars)] + input_var_names = var_names[len(conditioningVars):] # Estimate the full joint PDF _pdf = fastKDE(npy.array(fullVarList), positive_shift=positive_shift, **kwargs)