Please see below. On Mon, Oct 13, 2008 at 6:03 PM, <[EMAIL PROTECTED]> wrote: > Author: semor > Date: Mon Oct 13 18:03:23 2008 > New Revision: 7688 > > URL: http://svn.gna.org/viewcvs/relax?rev=7688&view=rev > Log: > Added the function for the NMRView peak list header handling. > > > Modified: > 1.3/generic_fns/intensity.py > > Modified: 1.3/generic_fns/intensity.py > URL: > http://svn.gna.org/viewcvs/relax/1.3/generic_fns/intensity.py?rev=7688&r1=7687&r2=7688&view=diff > ============================================================================== > --- 1.3/generic_fns/intensity.py (original) > +++ 1.3/generic_fns/intensity.py Mon Oct 13 18:03:23 2008 > @@ -226,23 +226,32 @@ > ######## > > # Loop over the lines of the file until a peak intensity value is reached. > - header_lines = 0 > - for i in xrange(len(file_data)): > - # Try to see if the intensity can be extracted. > - try: > - if int_col: > - intensity(file_data[i], int_col) > + if format == 'easy':
Shouldn't this be 'xeasy'? > + header_lines = 0 > + for i in xrange(len(file_data)): > + # Try to see if the intensity can be extracted. > + try: > + if int_col: > + intensity(file_data[i], int_col) > + else: > + intensity(file_data[i]) > + except RelaxError: > + header_lines = header_lines + 1 > + except IndexError: > + header_lines = header_lines + 1 > else: > - intensity(file_data[i]) > - except RelaxError: > - header_lines = header_lines + 1 > - except IndexError: > - header_lines = header_lines + 1 > - else: > - break > - > - # Return the number of lines. > - return header_lines > + break > + > + # Return the number of lines. > + return header_lines > + > + > + # NMRView. > + ########## > + > + # Assume the Sparky file has six header lines! Is this comment correct? > + elif format == 'nmrview': > + return 6 Regards, Edward _______________________________________________ relax (http://nmr-relax.com) This is the relax-devel mailing list [email protected] To unsubscribe from this list, get a password reminder, or change your subscription options, visit the list information page at https://mail.gna.org/listinfo/relax-devel

