Author: bugman Date: Tue Jan 20 14:07:07 2015 New Revision: 27239 URL: http://svn.gna.org/viewcvs/relax?rev=27239&view=rev Log: Merged revisions 27200-27230 via svnmerge from svn+ssh://bugman@xxxxxxxxxxx/svn/relax/trunk ........ r27200 | tlinnet | 2015-01-16 23:19:25 +0100 (Fri, 16 Jan 2015) | 3 lines Added save state for testing implementation of error analysis. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27201 | tlinnet | 2015-01-16 23:19:44 +0100 (Fri, 16 Jan 2015) | 4 lines Start of implementation of systemtest Relax_disp.test_task_7882_monte_carlo_std_residual, to test doing Monte-Carlo simulations with errors drawn from a Gauss distribution with a width corresponding to the standard devition of the sum of squares of residuals. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27202 | tlinnet | 2015-01-16 23:19:47 +0100 (Fri, 16 Jan 2015) | 3 lines Implemented target function for relaxation dispersion, which calculate the sum of squares of residuals and the standard deviation of these. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27203 | tlinnet | 2015-01-16 23:19:50 +0100 (Fri, 16 Jan 2015) | 3 lines Implemented storing of sum of squares and the standard deviation of these for relaxation dispersion, when doing a point calculation. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27204 | tlinnet | 2015-01-16 23:19:51 +0100 (Fri, 16 Jan 2015) | 3 lines Stored the sums of squares of the residuals "sos" and standard deviation of this "sos_std" per spin after optimisation. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27205 | tlinnet | 2015-01-16 23:19:54 +0100 (Fri, 16 Jan 2015) | 3 lines Added to systemtest Relax_disp.test_task_7882_monte_carlo_std_residual() that spin.sos and spin.sos_std is stored after grid search. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27206 | tlinnet | 2015-01-16 23:19:56 +0100 (Fri, 16 Jan 2015) | 3 lines Extracted "sos" and "sos_std" after grid search. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27207 | tlinnet | 2015-01-16 23:19:58 +0100 (Fri, 16 Jan 2015) | 3 lines In systemtest Relax_disp.test_task_7882_monte_carlo_std_residual() inserted sanity checks of calculation of degrees of freedom. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27208 | tlinnet | 2015-01-16 23:20:01 +0100 (Fri, 16 Jan 2015) | 5 lines Speed-up of systemtest Relax_disp.test_task_7882_monte_carlo_std_residual() by copying pipe instead of reading results 3 times. Tested creation of Monte-Carlo data, where errors are generated with width of standard deviation or residuals. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27209 | tlinnet | 2015-01-16 23:20:04 +0100 (Fri, 16 Jan 2015) | 3 lines Extended user function monte_carlo.create_data() to accept 'method="sum_squares"', to create Monte-Carlo data. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27210 | tlinnet | 2015-01-16 23:20:06 +0100 (Fri, 16 Jan 2015) | 3 lines Extended backend in pipe_control.error_analysis.monte_carlo_create_data() to return errors as the standard deviation of the sum of squares of the residual. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27211 | tlinnet | 2015-01-16 23:20:08 +0100 (Fri, 16 Jan 2015) | 3 lines Implemented the api_base method of return_error_sum_squares(), as raising an error if not defined for the api for the pipe_type. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27212 | tlinnet | 2015-01-16 23:20:11 +0100 (Fri, 16 Jan 2015) | 3 lines Implemented in the relaxation dispersion API, the function to return errors as the standard deviation of sums squared residuals. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27213 | tlinnet | 2015-01-16 23:20:13 +0100 (Fri, 16 Jan 2015) | 3 lines Added 'sos' and 'sos_std' as parameter object in relaxation dispersion. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27214 | tlinnet | 2015-01-17 14:16:50 +0100 (Sat, 17 Jan 2015) | 17 lines Reverted range of commits r27213:r27202 as this was a bad implementation. To get the distribution, one should look at the sum of squares. But this should be from the weighted sum of squares, which is stored as chi2. The API provides a method of model_statistics(), to get: k - number of parameters. n - number of data points. chi2 - the chi-squared value. Then reduced chi2 can be computed. chi2_red = chi2/(n-k) And the error distribution be drawn from this. The command used was: svn merge -r27213:r27201 . Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27215 | tlinnet | 2015-01-17 17:25:12 +0100 (Sat, 17 Jan 2015) | 3 lines Simplification of systemtest Relax_disp.test_task_7882_monte_carlo_std_residual, to just test the creation of Monte-Carlo data where errors are drawn from the reduced chi2 distribution. 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. ........ r27216 | tlinnet | 2015-01-17 17:25:15 +0100 (Sat, 17 Jan 2015) | 3 lines Extension of the userfunction monte_carlo.create_data, to draw errors from the reduced chi2 gauss distribution as found by best fit. 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. ........ r27217 | tlinnet | 2015-01-17 17:25:16 +0100 (Sat, 17 Jan 2015) | 3 lines Adding to back-end of pipe_control.error_analysis(), to modify datapoint as error drawn from the reduced chi2 gauss distribution. 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. ........ r27218 | tlinnet | 2015-01-17 17:25:18 +0100 (Sat, 17 Jan 2015) | 3 lines Adding empty API method to return errors from the reduced chi2 distribution. 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. ........ r27219 | tlinnet | 2015-01-17 17:25:20 +0100 (Sat, 17 Jan 2015) | 3 lines Added API function in relaxation dispersion to return error structure from the reduced chi2 distribution. 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. ........ r27220 | tlinnet | 2015-01-18 17:32:37 +0100 (Sun, 18 Jan 2015) | 8 lines Temporary test of making a confidence interval as described in fitting guide. This is systemtest Relax_disp.x_test_task_7882_kex_conf, which is not activated by default. Running the test, interestingely shows, there is a possibility for a lower global kex. But the value only differ from kex=1826 to kex=1813. 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. ........ r27221 | tlinnet | 2015-01-19 13:48:41 +0100 (Mon, 19 Jan 2015) | 8 lines Change to systemtest Relax_disp.x_test_task_7882_kex_conf() This is just a temporary systemtest, to check for local minima. This is method in regression book of Graphpad: http://www.graphpad.com/faq/file/Prism4RegressionBook.pdf Page: 109-111. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27222 | tlinnet | 2015-01-19 13:48:44 +0100 (Mon, 19 Jan 2015) | 3 lines Raising an error, if the R2eff model is used, and drawing errors from the fit. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27223 | tlinnet | 2015-01-19 13:48:46 +0100 (Mon, 19 Jan 2015) | 3 lines To systemtest Relax_disp.test_task_7882_monte_carlo_std_residual(), adding test for raise of errors, if the R2eff model is selected. Task #7882 (https://gna.org/task/?7882): Implement Monte-Carlo simulation, where errors are generated with width of standard deviation or residuals. ........ r27224 | tlinnet | 2015-01-20 12:02:01 +0100 (Tue, 20 Jan 2015) | 5 lines 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. ........ r27225 | tlinnet | 2015-01-20 12:02:10 +0100 (Tue, 20 Jan 2015) | 5 lines Extended the user function 'monte_carlo.create_data', to allow for the defition of the STD to use in gauss distribution. This is for creation of Monte-Carlo simulations, where one has perhaps gained information about the expected errors of the datapoints, which is not measured. 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. ........ r27226 | tlinnet | 2015-01-20 12:02:12 +0100 (Tue, 20 Jan 2015) | 5 lines In backend pipe_control.error_analysis.monte_carlo_create_data() added the argument 'fixed_error' to allow for fixed input of error to the gauss distribution. Inserted a range of checks, to make sure function behaves as expected. 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. ........ r27227 | tlinnet | 2015-01-20 12:02:14 +0100 (Tue, 20 Jan 2015) | 3 lines Added to pipe_control.error_analysis.monte_carlo_create_data() the creation of datapoints for a fixed distribution. 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. ........ r27228 | tlinnet | 2015-01-20 12:02:16 +0100 (Tue, 20 Jan 2015) | 4 lines To systemtest Relax_disp.test_task_7882_monte_carlo_std_residual(), added tests for creation of Monte-Carlo data by different methods. 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. ........ r27229 | tlinnet | 2015-01-20 12:41:21 +0100 (Tue, 20 Jan 2015) | 4 lines In pipe_control.error_analysis.monte_carlo_create_data(), if data is of list type or ndarray, then modify the datapoint according to the fixed error if the distribution is set to 'fixed'. 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. ........ r27230 | tlinnet | 2015-01-20 12:41:23 +0100 (Tue, 20 Jan 2015) | 5 lines Expanded the STD acronym, to the meaning of Standard deviation. This is in the user function 'monte_carlo.create_data'. 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. ........ Added: branches/frame_order_cleanup/test_suite/shared_data/dispersion/error_testing/task_7882.bz2 - copied unchanged from r27230, trunk/test_suite/shared_data/dispersion/error_testing/task_7882.bz2 Modified: branches/frame_order_cleanup/ (props changed) branches/frame_order_cleanup/pipe_control/error_analysis.py branches/frame_order_cleanup/specific_analyses/api_base.py branches/frame_order_cleanup/specific_analyses/relax_disp/api.py branches/frame_order_cleanup/test_suite/system_tests/relax_disp.py branches/frame_order_cleanup/user_functions/monte_carlo.py [This mail would be too long, it was shortened to contain the URLs only.] Modified: branches/frame_order_cleanup/pipe_control/error_analysis.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/pipe_control/error_analysis.py?rev=27239&r1=27238&r2=27239&view=diff Modified: branches/frame_order_cleanup/specific_analyses/api_base.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/specific_analyses/api_base.py?rev=27239&r1=27238&r2=27239&view=diff Modified: branches/frame_order_cleanup/specific_analyses/relax_disp/api.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/specific_analyses/relax_disp/api.py?rev=27239&r1=27238&r2=27239&view=diff Modified: branches/frame_order_cleanup/test_suite/system_tests/relax_disp.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/test_suite/system_tests/relax_disp.py?rev=27239&r1=27238&r2=27239&view=diff Modified: branches/frame_order_cleanup/user_functions/monte_carlo.py URL: http://svn.gna.org/viewcvs/relax/branches/frame_order_cleanup/user_functions/monte_carlo.py?rev=27239&r1=27238&r2=27239&view=diff