Difference between revisions of "Spin loop"

From relax wiki
Jump to navigation Jump to search
Line 10: Line 10:
 
for spin, spin_id in spin_loop(return_id=True, skip_desel=True):
 
for spin, spin_id in spin_loop(return_id=True, skip_desel=True):
 
     print("Spin '%s', model '%s'" % (spin_id, spin.model))
 
     print("Spin '%s', model '%s'" % (spin_id, spin.model))
 +
</source>
  
# To see available information in the spin class
+
To see available information in the spin class
 +
<source lang="python">
 
dir(spin)
 
dir(spin)
 +
dir(spin)
 +
['__class__', '__clone__', '__deepcopy__', '__delattr__', '__dict__', '__doc__', '__format__', '__getattribute__', '__hash__', '__init__',
 +
'__module__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__',
 +
'__subclasshook__', '__weakref__', '_back_compat_hook', '_back_compat_hook_mf_data', '_back_compat_hook_ri_data',
 +
'_mol_index', '_mol_name', '_res_index', '_res_name', '_res_num', '_spin_ids', '_spin_index',
 +
'chi2', 'chi2_sim', 'f_count', 'f_count_sim', 'g_count', 'g_count_sim', 'h_count', 'h_count_sim', 'intensities', 'intensity_err', 'is_empty',
 +
'isotope', 'iter', 'iter_sim', 'kex', 'kex_err', 'kex_sim', 'model', 'name', 'num', 'params', 'phi_ex', 'phi_ex_err',
 +
'phi_ex_sim', 'r2', 'r2_err', 'r2_sim', 'r2eff', 'r2eff_bc', 'r2eff_err', 'r2eff_sim', 'select', 'select_sim', 'warning', 'warning_sim']
 
</source>
 
</source>
  
 
== See also ==
 
== See also ==
 
[[Category:Results]]
 
[[Category:Results]]

Revision as of 14:00, 17 June 2013

View results per spin

  1. Looking at the contents of the spin viewer window in the GUI,
  2. Opening a relax results or state XML file in a text editor,
  3. Looking at the cdp.mol[i].res[j].spin[k] data structure.


Looping

from pipe_control.mol_res_spin import spin_loop
for spin, spin_id in spin_loop(return_id=True, skip_desel=True):
    print("Spin '%s', model '%s'" % (spin_id, spin.model))

To see available information in the spin class

dir(spin)
dir(spin)
['__class__', '__clone__', '__deepcopy__', '__delattr__', '__dict__', '__doc__', '__format__', '__getattribute__', '__hash__', '__init__', 
'__module__', '__new__', '__reduce__', '__reduce_ex__', '__repr__', '__setattr__', '__sizeof__', '__str__', 
'__subclasshook__', '__weakref__', '_back_compat_hook', '_back_compat_hook_mf_data', '_back_compat_hook_ri_data', 
'_mol_index', '_mol_name', '_res_index', '_res_name', '_res_num', '_spin_ids', '_spin_index', 
'chi2', 'chi2_sim', 'f_count', 'f_count_sim', 'g_count', 'g_count_sim', 'h_count', 'h_count_sim', 'intensities', 'intensity_err', 'is_empty', 
'isotope', 'iter', 'iter_sim', 'kex', 'kex_err', 'kex_sim', 'model', 'name', 'num', 'params', 'phi_ex', 'phi_ex_err', 
'phi_ex_sim', 'r2', 'r2_err', 'r2_sim', 'r2eff', 'r2eff_bc', 'r2eff_err', 'r2eff_sim', 'select', 'select_sim', 'warning', 'warning_sim']

See also