def calculate_percentages()

in dagify/converter/utils.py [0:0]


def calculate_percentages(not_converted, converted):
    """Function to calculate the percentages"""
    total = len(not_converted) + len(converted)
    non_converted_percent = round((len(not_converted) / total) * 100, 2)
    converted_percent = round(100 - non_converted_percent, 2)

    return non_converted_percent, converted_percent