def get_dist(Y, W, domain):
 return np.bincount(Y, weights=W, minlength=len(domain.class_var.values))

def get_dist ( Y , W , domain ) : return np . bincount ( Y , weights = W , minlength = len ( domain . class_var . values ) )
determine the class distribution for a given array of classifications .