diff options
author | zsloan | 2021-11-12 16:27:03 +0000 |
---|---|---|
committer | zsloan | 2021-11-12 16:27:03 +0000 |
commit | e2647916b051f5d46ccb24e08a6c97cbb8f668f2 (patch) | |
tree | 208d44052251096d4cce5c9dc8876066285dc403 | |
parent | fd4abaaeb18c31b1d0d8474fe2229d5a31bfc20d (diff) | |
download | genenetwork2-e2647916b051f5d46ccb24e08a6c97cbb8f668f2.tar.gz |
This change prevents an error caused by trying to export mapping results for a ProbeSet trait when there is no gene symbol
-rw-r--r-- | wqflask/wqflask/marker_regression/run_mapping.py | 3 |
1 files changed, 2 insertions, 1 deletions
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: |