Author: bugman Date: Mon Nov 7 16:51:14 2011 New Revision: 14979 URL: http://svn.gna.org/viewcvs/relax?rev=14979&view=rev Log: Fix for the pymol.cone_pdb user function for frame order models with no alpha average pos angle. This is specifically for the isotropic cone, free rotor model. But other models might also be affected by this fix. Modified: 1.3/generic_fns/pymol_control.py Modified: 1.3/generic_fns/pymol_control.py URL: http://svn.gna.org/viewcvs/relax/1.3/generic_fns/pymol_control.py?rev=14979&r1=14978&r2=14979&view=diff ============================================================================== --- 1.3/generic_fns/pymol_control.py (original) +++ 1.3/generic_fns/pymol_control.py Mon Nov 7 16:51:14 2011 @@ -305,10 +305,13 @@ ################################# # Check if there is an average position. - if hasattr(cdp, 'ave_pos_alpha'): + if hasattr(cdp, 'ave_pos_beta'): # The average position rotation. ave_pos_R = zeros((3, 3), float64) - euler_to_R_zyz(cdp.ave_pos_alpha, cdp.ave_pos_beta, cdp.ave_pos_gamma, ave_pos_R) + ave_pos_alpha = 0.0 + if hasattr(cdp, 'ave_pos_alpha') and cdp.ave_pos_alpha != None: + ave_pos_alpha = cdp.ave_pos_alpha + euler_to_R_zyz(ave_pos_alpha, cdp.ave_pos_beta, cdp.ave_pos_gamma, ave_pos_R) # The rotation is passive (need to rotated the moving domain back into the average position defined in the non-moving domain PDB frame). R = transpose(ave_pos_R)