From 18a3197be181d4a180527ba859ee13de0204e0ac Mon Sep 17 00:00:00 2001
From: Joana Pereira <joanapereira@4414.bioz.unibas.ch>
Date: Sat, 22 Jul 2023 09:24:09 +0200
Subject: [PATCH] fixed issue with plotting when the parameter was not possible
 to compute

---
 barrOs_library.py | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/barrOs_library.py b/barrOs_library.py
index 23db097..af455b1 100644
--- a/barrOs_library.py
+++ b/barrOs_library.py
@@ -2318,7 +2318,13 @@ def run_barros(arguments, offset = 1, step = 2, local_angle_threshold = 25, dist
             else:
                 target_chains = None
         else:
-            target_chains = [[pdbID.split('_')[0], chainID, pdb_file, protein_type, membrane_thickness]]
+            if 'AF-' not in pdbID:
+                target_chains = [[pdbID.split('_')[0], chainID, pdb_file, protein_type, membrane_thickness]]
+            else:
+                try:
+                    target_chains = [[pdbID.split('/')[1], chainID, pdb_file, protein_type, membrane_thickness]]
+                except:
+                    target_chains = [[pdbID, chainID, pdb_file, protein_type, membrane_thickness]]
 
         if pdb_file != 'not available' and protein_type != 'not available' and target_chains is not None:
             if input_mode != 'all':
-- 
GitLab