mailr19939 - /branches/relax_disp/specific_analyses/relax_disp/__init__.py


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

Header


Content

Posted by edward on June 07, 2013 - 13:34:
Author: bugman
Date: Fri Jun  7 13:34:09 2013
New Revision: 19939

URL: http://svn.gna.org/viewcvs/relax?rev=19939&view=rev
Log:
More improvements to the relax_disp.plot_disp_curves user function.

The graph axes maximum is now set to a reasonable value for the given data.


Modified:
    branches/relax_disp/specific_analyses/relax_disp/__init__.py

Modified: branches/relax_disp/specific_analyses/relax_disp/__init__.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/__init__.py?rev=19939&r1=19938&r2=19939&view=diff
==============================================================================
--- branches/relax_disp/specific_analyses/relax_disp/__init__.py (original)
+++ branches/relax_disp/specific_analyses/relax_disp/__init__.py Fri Jun  7 
13:34:09 2013
@@ -634,6 +634,7 @@
             # Initialise some data structures.
             data = []
             set_labels = []
+            axis_max = [0, 0]
             x_err_flag = False
             y_err_flag = False
 
@@ -665,6 +666,12 @@
                     # Add the data.
                     data[-1].append([disp_point, spin.r2eff[key]])
 
+                    # Extend the Grace world.
+                    if disp_point > axis_max[0]:
+                        axis_max[0] = disp_point
+                    if spin.r2eff[key] > axis_max[1]:
+                        axis_max[1] = spin.r2eff[key]
+
                     # Add the error.
                     if hasattr(spin, 'r2eff_err') and key in spin.r2eff_err:
                         err = True
@@ -736,7 +743,7 @@
 
             # Write the header.
             title = "Relaxation dispersion plot"
-            write_xy_header(file=file, title=title, sets=len(data), 
set_names=set_labels, axis_labels=axis_labels)
+            write_xy_header(file=file, title=title, sets=len(data), 
set_names=set_labels, axis_labels=axis_labels, axis_max=axis_max)
 
             # Write the data.
             graph_type = 'xy'




Related Messages


Powered by MHonArc, Updated Fri Jun 07 14:00:02 2013