def merge_distributions(distribution, new_distribution):
    """Adds up a new distribution structure to a map formatted distribution

    """
    for value, instances in new_distribution.items():
        if distribution not in value:
            distribution[value] = 0
        distribution[value] += instances
    return distribution
dataset/ETHPy150Open bigmlcom/python/bigml/multivote.py/merge_distributions/swapped operands of `not in`