mailr22791 - /trunk/lib/software/grace.py


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

Header


Content

Posted by edward on April 16, 2014 - 16:04:
Author: bugman
Date: Wed Apr 16 16:04:59 2014
New Revision: 22791

URL: http://svn.gna.org/viewcvs/relax?rev=22791&view=rev
Log:
Removed the automatic axis labelling in the 
lib.software.grace.write_xy_header() function.

This is the automatic labelling based on the parameter Grace strings and 
units of the specific
analysis type.  This is now preformed by the specific analyses themselves so 
the automatic code is
not needed or used.

This allows the dependence on the pipe_control.pipes module and the specific 
analysis API to be
removed making the relax library now 100% independent from the rest of relax.


Modified:
    trunk/lib/software/grace.py

Modified: trunk/lib/software/grace.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/lib/software/grace.py?rev=22791&r1=22790&r2=22791&view=diff
==============================================================================
--- trunk/lib/software/grace.py (original)
+++ trunk/lib/software/grace.py Wed Apr 16 16:04:59 2014
@@ -26,10 +26,6 @@
 # Python module imports.
 from math import ceil, sqrt
 from re import search
-
-# relax module imports.
-from pipe_control import pipes
-from specific_analyses.api import return_api
 
 # This script is used to batch convert the Grace *.agr files into graphics 
files using the Grace
 # program itself.
@@ -356,15 +352,6 @@
         # Axis specific settings.
         axes = ['x', 'y']
         for i in range(2):
-            # Analysis specific methods for making labels.
-            analysis_spec = False
-            if pipes.cdp_name():
-                # Flag for making labels.
-                analysis_spec = True
-
-                # The specific analysis API object.
-                api = return_api()
-
             # Some axis default values for spin data.
             if data_type[i] == 'spin':
                 # Residue only data.
@@ -383,32 +370,7 @@
                 if seq_type[i] == 'mixed':
                     # X-axis label.
                     if not axis_labels[gi][i]:
-                        axis_labels[gi][i] = "Spin identification string"
-
-            # Some axis default values for other data types.
-            else:
-                # Label.
-                if analysis_spec and (not axis_labels or not 
axis_labels[gi][i]):
-                    # Strip out the '_err' and '_bc' from the data type to 
allow the error and back-calculated structures to be used.
-                    data_type_i = data_type[i]
-                    if search('_err$', data_type_i):
-                        data_type_i = data_type_i[:-4]
-                    elif search('_bc$', data_type_i):
-                        data_type_i = data_type_i[:-3]
-
-                    # Get the units.
-                    units = api.return_units(data_type_i)
-
-                    # Set the label.
-                    axis_labels[gi][i] = api.return_grace_string(data_type_i)
-
-                    # Add units.
-                    if units:
-                        axis_labels[gi][i] = axis_labels[gi][i] + "\\N (" + 
units + ")"
-
-                    # Normalised data.
-                    if norm and norm[gi] and axes[i] == 'y':
-                        axis_labels[gi][i] = axis_labels[gi][i] + " 
\\N\\q(normalised)\\Q"
+                        axis_labels[gi][i] = "Spin ID string"
 
             # Write out the data.
             if axis_labels[gi][i]:




Related Messages


Powered by MHonArc, Updated Wed Apr 16 16:20:02 2014