mailr5279 - /1.3/generic_fns/grace.py


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

Header


Content

Posted by sebastien . morin . 1 on April 03, 2008 - 22:24:
Author: semor
Date: Thu Apr  3 22:24:13 2008
New Revision: 5279

URL: http://svn.gna.org/viewcvs/relax?rev=5279&view=rev
Log:
Reverted revision 5268.

The command used was:
svn merge -r5268:5267 .

Too many errors were present as noted by Edward d'Auvergne in a post at:
https://mail.gna.org/public/relax-devel/2008-04/msg00022.html (Message-id:
<7f080ed10804031148r75a295a2u99569bb13b99ffc5@xxxxxxxxxxxxxx>)


Modified:
    1.3/generic_fns/grace.py

Modified: 1.3/generic_fns/grace.py
URL: 
http://svn.gna.org/viewcvs/relax/1.3/generic_fns/grace.py?rev=5279&r1=5278&r2=5279&view=diff
==============================================================================
--- 1.3/generic_fns/grace.py (original)
+++ 1.3/generic_fns/grace.py Thu Apr  3 22:24:13 2008
@@ -103,29 +103,29 @@
        cdp = relax_data_store[relax_data_store.current_pipe]
 
         # Loop over the residues.
-        for spin in spin_loop(spin_id):
+        for i in xrange(len(cdp.res)):
             # Remap the data structure 'cdp.res[i]'.
-            spin = cdp.res[i]
+            data = cdp.res[i]
 
             # Skip the residue if there is no match to 'self.res_num' 
(unless it is None).
             if type(self.res_num) == int:
-                if not spin.num == self.res_num:
+                if not data.num == self.res_num:
                     continue
             elif type(self.res_num) == str:
-                if not match(self.res_num, `spin.num`):
+                if not match(self.res_num, `data.num`):
                     continue
 
             # Skip the residue if there is no match to 'self.res_name' 
(unless it is None).
             if self.res_name != None:
-                if not match(self.res_name, spin.name):
+                if not match(self.res_name, data.name):
                     continue
 
             # Skip deselected residues.
-            if not spin.select:
+            if not data.select:
                 continue
 
             # Number of data points per residue.
-            if self.plot_spin == 'sim':
+            if self.plot_data == 'sim':
                 points = cdp.sim_number
             else:
                 points = 1
@@ -133,43 +133,43 @@
             # Loop over the data points.
             for j in xrange(points):
                 # Initialise an empty array for the individual residue data.
-                res_spin = [spin.num, spin.name, None, None, None, None]
+                res_data = [data.num, data.name, None, None, None, None]
 
                 # Residue number on the x-axis.
-                if self.x_spin_type == 'res':
-                    res_spin[2] = spin.num
+                if self.x_data_type == 'res':
+                    res_data[2] = data.num
 
                 # Parameter value for the x-axis.
                 else:
                     # Get the x-axis values and errors.
-                    if self.plot_spin == 'sim':
-                        res_spin[2], res_spin[3] = 
self.x_return_value(self.run, i, self.x_spin_type, sim=j)
+                    if self.plot_data == 'sim':
+                        res_data[2], res_data[3] = 
self.x_return_value(self.run, i, self.x_data_type, sim=j)
                     else:
-                        res_spin[2], res_spin[3] = 
self.x_return_value(self.run, i, self.x_spin_type)
+                        res_data[2], res_data[3] = 
self.x_return_value(self.run, i, self.x_data_type)
 
                 # Get the y-axis values and errors.
-                if self.plot_spin == 'sim':
-                    res_spin[4], res_spin[5] = self.y_return_value(self.run, 
i, self.y_spin_type, sim=j)
+                if self.plot_data == 'sim':
+                    res_data[4], res_data[5] = self.y_return_value(self.run, 
i, self.y_data_type, sim=j)
                 else:
-                    res_spin[4], res_spin[5] = self.y_return_value(self.run, 
i, self.y_spin_type)
+                    res_data[4], res_data[5] = self.y_return_value(self.run, 
i, self.y_data_type)
 
                 # Go to the next residue if there is missing data.
-                if res_spin[2] == None or res_spin[4] == None:
+                if res_data[2] == None or res_data[4] == None:
                     continue
 
                 # X-axis conversion factors.
-                if self.x_spin_type != 'res':
-                    res_spin[2] = array(res_spin[2]) / 
self.x_return_conversion_factor(self.x_spin_type)
-                    if res_spin[3]:
-                        res_spin[3] = array(res_spin[3]) / 
self.x_return_conversion_factor(self.x_spin_type)
+                if self.x_data_type != 'res':
+                    res_data[2] = array(res_data[2]) / 
self.x_return_conversion_factor(self.x_data_type)
+                    if res_data[3]:
+                        res_data[3] = array(res_data[3]) / 
self.x_return_conversion_factor(self.x_data_type)
 
                 # Y-axis conversion factors.
-                res_spin[4] = array(res_spin[4]) / 
self.y_return_conversion_factor(self.y_spin_type)
-                if res_spin[5]:
-                    res_spin[5] = array(res_spin[5]) / 
self.y_return_conversion_factor(self.y_spin_type)
+                res_data[4] = array(res_data[4]) / 
self.y_return_conversion_factor(self.y_data_type)
+                if res_data[5]:
+                    res_data[5] = array(res_data[5]) / 
self.y_return_conversion_factor(self.y_data_type)
 
                 # Append the array to the full data structure.
-                self.spin.append(res_spin)
+                self.data.append(res_data)
 
 
     def view(self, file=None, dir=None, grace_exe='xmgrace'):




Related Messages


Powered by MHonArc, Updated Thu Apr 03 22:40:15 2008