Author: bugman Date: Sun Jun 10 13:15:22 2012 New Revision: 16805 URL: http://svn.gna.org/viewcvs/relax?rev=16805&view=rev Log: BMRB output improvements - deselected spins are no longer skipped! The model-free BMRB output is also more robust to missing data. Modified: branches/uf_redesign/generic_fns/diffusion_tensor.py branches/uf_redesign/generic_fns/relax_data.py branches/uf_redesign/specific_fns/model_free/bmrb.py Modified: branches/uf_redesign/generic_fns/diffusion_tensor.py URL: http://svn.gna.org/viewcvs/relax/branches/uf_redesign/generic_fns/diffusion_tensor.py?rev=16805&r1=16804&r2=16805&view=diff ============================================================================== --- branches/uf_redesign/generic_fns/diffusion_tensor.py (original) +++ branches/uf_redesign/generic_fns/diffusion_tensor.py Sun Jun 10 13:15:22 2012 @@ -168,10 +168,6 @@ # Store the spin specific data in lists for later use. for spin, mol_name, res_num, res_name, spin_id in spin_loop(full_info=True, return_id=True): - # Skip deselected spins. - if not spin.select: - continue - # Check the data for None (not allowed in BMRB!). if res_num == None: raise RelaxError("For the BMRB, the residue of spin '%s' must be numbered." % spin_id) Modified: branches/uf_redesign/generic_fns/relax_data.py URL: http://svn.gna.org/viewcvs/relax/branches/uf_redesign/generic_fns/relax_data.py?rev=16805&r1=16804&r2=16805&view=diff ============================================================================== --- branches/uf_redesign/generic_fns/relax_data.py (original) +++ branches/uf_redesign/generic_fns/relax_data.py Sun Jun 10 13:15:22 2012 @@ -248,10 +248,6 @@ # Store the spin specific data in lists for later use. for spin, mol_name, res_num, res_name, spin_id in spin_loop(full_info=True, return_id=True): - # Skip deselected spins. - if not spin.select: - continue - # Skip spins with no relaxation data. if not hasattr(spin, 'ri_data'): continue Modified: branches/uf_redesign/specific_fns/model_free/bmrb.py URL: http://svn.gna.org/viewcvs/relax/branches/uf_redesign/specific_fns/model_free/bmrb.py?rev=16805&r1=16804&r2=16805&view=diff ============================================================================== --- branches/uf_redesign/specific_fns/model_free/bmrb.py (original) +++ branches/uf_redesign/specific_fns/model_free/bmrb.py Sun Jun 10 13:15:22 2012 @@ -428,10 +428,6 @@ # Store the spin specific data in lists for later use. for spin, mol_name, res_num, res_name, spin_id in spin_loop(full_info=True, return_id=True): - # Skip deselected spins. - if not spin.select: - continue - # Check the data for None (not allowed in BMRB!). if res_num == None: raise RelaxError("For the BMRB, the residue of spin '%s' must be numbered." % spin_id) @@ -450,11 +446,29 @@ res_name_list.append(res_name) atom_name_list.append(spin.name) - # Values. - csa_list.append(spin.csa * 1e6) # In ppm. - r_list.append(spin.r) - isotope_list.append(int(string.strip(spin.heteronuc_type, string.ascii_letters))) - element_list.append(spin.element) + # CSA values. + if hasattr(spin, 'csa'): + csa_list.append(spin.csa * 1e6) # In ppm. + else: + csa_list.append(None) + + # Bond lengths. + if hasattr(spin, 'csa'): + r_list.append(spin.r) + else: + r_list.append(None) + + # The heteronucleus type. + if hasattr(spin, 'csa'): + isotope_list.append(int(string.strip(spin.heteronuc_type, string.ascii_letters))) + else: + isotope_list.append(None) + + # The element. + if hasattr(spin, 'element'): + element_list.append(spin.element) + else: + element_list.append(None) # Diffusion tensor. local_tm_list.append(spin.local_tm)