From e2647916b051f5d46ccb24e08a6c97cbb8f668f2 Mon Sep 17 00:00:00 2001 From: zsloan Date: Fri, 12 Nov 2021 16:27:03 +0000 Subject: This change prevents an error caused by trying to export mapping results for a ProbeSet trait when there is no gene symbol --- wqflask/wqflask/marker_regression/run_mapping.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/wqflask/wqflask/marker_regression/run_mapping.py b/wqflask/wqflask/marker_regression/run_mapping.py index 769b9240..9d70bb15 100644 --- a/wqflask/wqflask/marker_regression/run_mapping.py +++ b/wqflask/wqflask/marker_regression/run_mapping.py @@ -556,7 +556,8 @@ def export_mapping_results(dataset, trait, markers, results_path, mapping_method transform_text = "" output_file.write(transform_text + "\n") if dataset.type == "ProbeSet": - output_file.write("Gene Symbol: " + trait.symbol + "\n") + if trait.symbol: + output_file.write("Gene Symbol: " + trait.symbol + "\n") output_file.write("Location: " + str(trait.chr) + \ " @ " + str(trait.mb) + " Mb\n") if len(covariates) > 0: -- cgit v1.2.3