mailr27224 - /trunk/pipe_control/error_analysis.py


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

Header


Content

Posted by tlinnet on January 20, 2015 - 12:02:
Author: tlinnet
Date: Tue Jan 20 12:02:01 2015
New Revision: 27224

URL: http://svn.gna.org/viewcvs/relax?rev=27224&view=rev
Log:
Added test of argument "distribution" in 
Ãpipe_control.error_analysis.monte_carlo_create_data().

This is to make sure that a wrong argument is not passed into the function.

Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, 
where errors are generated with width of standard deviation or residuals.): 
Implement Monte-Carlo simulation, where errors are generated with width of 
standard deviation or residuals.

Modified:
    trunk/pipe_control/error_analysis.py

Modified: trunk/pipe_control/error_analysis.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/pipe_control/error_analysis.py?rev=27224&r1=27223&r2=27224&view=diff
==============================================================================
--- trunk/pipe_control/error_analysis.py        (original)
+++ trunk/pipe_control/error_analysis.py        Tue Jan 20 12:02:01 2015
@@ -92,6 +92,11 @@
     valid_methods = ['back_calc', 'direct']
     if method not in valid_methods:
         raise RelaxError("The simulation creation method " + repr(method) + 
" is not valid.")
+
+    # Test the distribution argument.
+    valid_distributions = ['measured', 'red_chi2']
+    if distribution not in valid_distributions:
+        raise RelaxError("The simulation error distribution method " + 
repr(distribution) + " is not valid.  Try one of the following: " + 
repr(valid_distributions))
 
     # The specific analysis API object.
     api = return_api()




Related Messages


Powered by MHonArc, Updated Tue Jan 20 12:20:02 2015