Author: bugman Date: Fri Jun 7 00:39:31 2013 New Revision: 19933 URL: http://svn.gna.org/viewcvs/relax?rev=19933&view=rev Log: Python 3 fix for the relax_disp.cluster user function. Modified: branches/relax_disp/specific_analyses/relax_disp/__init__.py Modified: branches/relax_disp/specific_analyses/relax_disp/__init__.py URL: http://svn.gna.org/viewcvs/relax/branches/relax_disp/specific_analyses/relax_disp/__init__.py?rev=19933&r1=19932&r2=19933&view=diff ============================================================================== --- branches/relax_disp/specific_analyses/relax_disp/__init__.py (original) +++ branches/relax_disp/specific_analyses/relax_disp/__init__.py Fri Jun 7 00:39:31 2013 @@ -249,11 +249,14 @@ cdp.clustering[cluster_id].append(id) # Clean up - delete any empty clusters (except the free spins). + clean = [] for key in cdp.clustering.keys(): if key == 'free spins': continue if cdp.clustering[key] == []: - cdp.clustering.pop(key) + clean.append(key) + for key in clean: + cdp.clustering.pop(key) def _cluster_ids(self):