From 5ec98f87f56a781b814abc05d9de6f1fe8d0c7ac Mon Sep 17 00:00:00 2001 From: zsloan Date: Wed, 31 Aug 2022 19:17:57 +0000 Subject: Change qnorm parameter to transform, so other transforms can be added later --- wqflask/wqflask/api/mapping.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/wqflask/wqflask/api/mapping.py b/wqflask/wqflask/api/mapping.py index 42de6bb7..94e37161 100644 --- a/wqflask/wqflask/api/mapping.py +++ b/wqflask/wqflask/api/mapping.py @@ -50,7 +50,7 @@ def do_mapping_for_api(start_vars): if not in_trait_data: vals.append("x") - if mapping_params['qnorm']: + if mapping_params['transform'] == "qnorm": vals_minus_x = [float(val) for val in vals if val != "x"] qnorm_vals = normf(vals_minus_x) qnorm_vals_with_x = [] @@ -165,9 +165,9 @@ def initialize_parameters(start_vars, dataset, this_trait): except: mapping_params['perm_check'] = False - mapping_params['qnorm'] = False - if 'qnorm' in start_vars: - mapping_params['qnorm'] = True + mapping_params['transform'] = False + if 'transform' in start_vars: + mapping_params['transform'] = start_vars['transform'] mapping_params['genofile'] = False if 'genofile' in start_vars: -- cgit v1.2.3