def accuracy()

in results/summarize_presupposition_results.py [0:0]


def accuracy(data):
    n_correct = 0
    n_total = 0
    for d in data:
        d["correct"] = correct_prediction(d)
        if correct_prediction(d):
            n_correct += 1
        n_total += 1
    return n_correct / n_total