Author: bugman Date: Fri May 3 12:02:59 2013 New Revision: 19629 URL: http://svn.gna.org/viewcvs/relax?rev=19629&view=rev Log: Created the specific_analyses.relax_disp.disp_data.loop_all_data() function. This is to loop over all possible base relaxation dispersion data (spectrometer frequencies then dispersion points). Modified: branches/relax_disp/specific_analyses/relax_disp/disp_data.py Modified: branches/relax_disp/specific_analyses/relax_disp/disp_data.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/disp_data.py?rev=19629&r1=19628&r2=19629&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/disp_data.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/disp_data.py Fri May 3 12:02:59 2013 @@ -142,6 +142,21 @@ # Return the unique key. return common_key[0] + + +def loop_all_data(): + """Generator method for looping over the spectrometer frequency and dispersion points. + + @return: The spectrometer frequency and dispersion point data (either the spin-lock field strength in Hz or the nu_CPMG frequency in Hz). + @rtype: float, float + """ + + # First loop over the spectrometer frequencies. + for frq in loop_spectometer(): + # Then the dispersion points. + for point in loop_dispersion_point(): + # Return both. + yield frq, point def loop_dispersion_point():