mailr17106 - /branches/interatomic/relax_io.py


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on June 28, 2012 - 18:23:
Author: bugman
Date: Thu Jun 28 18:23:47 2012
New Revision: 17106

URL: http://svn.gna.org/viewcvs/relax?rev=17106&view=rev
Log:
The relax_io.read_spin_data() function can now handle spin IDs in quotes.


Modified:
    branches/interatomic/relax_io.py

Modified: branches/interatomic/relax_io.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/interatomic/relax_io.py?rev=17106&r1=17105&r2=17106&view=diff
==============================================================================
--- branches/interatomic/relax_io.py (original)
+++ branches/interatomic/relax_io.py Thu Jun 28 18:23:47 2012
@@ -536,6 +536,11 @@
     # Yield the data, spin by spin.
     missing_data = True
     for line in file_data:
+        # Convert the spin IDs.
+        if spin_id_col != None and line[spin_id_col-1][0] in ["\"", "\'"]:
+            line[spin_id_col-1] = eval(line[spin_id_col-1])
+
+        # Convert.
         # Validate the sequence.
         try:
             generic_fns.sequence.validate_sequence(line, 
spin_id_col=spin_id_col, mol_name_col=mol_name_col, res_num_col=res_num_col, 
res_name_col=res_name_col, spin_num_col=spin_num_col, 
spin_name_col=spin_name_col, data_col=data_col, error_col=error_col)




Related Messages


Powered by MHonArc, Updated Thu Jun 28 18:40:02 2012