def determine_target_cluster(success_labels, cluster_labels, cluster_count):
    """Determines the target cluster by calculating % of successes (response variable) for each
    cluster. Returns the cluster index with the higher % success.

        Args:
            success_labels (numpy array): The response variable column
            cluster_labels (numpy array): the cluster labelling
            cluster_count (int): the number of clusters

        Returns:
            (int): the cluster with the highest successes
        """
    # Variables to remember which is the current highest cluster
    max_percentage = 0
    cluster_index = None

    # Iterate through all clusters
    for i in range(cluster_count):

        # Extract only the cases related to this cluster
        partial = success_labels[cluster_labels == i]

        # Determine successes ie. response variable equal to 1
        successes = len(partial[partial == 1])

        # Percentage of successes
        percentage = successes / len(partial)

        # Replace the current max if this is higher
        if percentage > max_percentage:
            max_percentage = percentage
            cluster_index = i

    # Return the cluster index that has the highest % Successes
    return cluster_index