From b0380f32eb5b85abaf33527cfb37eb230e1af043 Mon Sep 17 00:00:00 2001
From: hjulienne <hanna.julienne@gmail.com>
Date: Tue, 8 Dec 2020 18:19:09 +0100
Subject: [PATCH] add debug print

---
 jass_preprocessing/__main__.py | 2 ++
 jass_preprocessing/map_gwas.py | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/jass_preprocessing/__main__.py b/jass_preprocessing/__main__.py
index 248bb16..6570db6 100644
--- a/jass_preprocessing/__main__.py
+++ b/jass_preprocessing/__main__.py
@@ -59,7 +59,9 @@ def launch_preprocessing(args):
 
         ref = jp.map_reference.read_reference(args.ref_path, bool(args.mask_MHC), float(args.minimum_MAF), region_to_mask=eval(args.additional_masked_region))
         print(ref.shape)
+        print(ref.head())
         print(gw_df.shape)
+        print(gw_df.head())
         mgwas = jp.map_reference.map_on_ref_panel(gw_df, ref, gwas_map.loc[tag, "index_type"])
         print(mgwas.shape)
         mgwas = jp.map_reference.compute_snp_alignement(mgwas)
diff --git a/jass_preprocessing/map_gwas.py b/jass_preprocessing/map_gwas.py
index 402b382..9d4c94d 100644
--- a/jass_preprocessing/map_gwas.py
+++ b/jass_preprocessing/map_gwas.py
@@ -134,7 +134,7 @@ def read_gwas( gwas_internal_link, column_map, imputation_treshold=None):
 
     print("Reading file:")
     print(gwas_internal_link)
-    is_gzipped = re.search(r".gz$", gwas_internal_link)
+    is_gzipped = re.search(r".gz|.bgz$", gwas_internal_link)
 
     if is_gzipped:
         compression = 'gzip'
-- 
GitLab