def organize_probabilities(probs, times, diff):
    """ This function organizes the predicted
    win probability into a form more amenable
    to visualization

    @param probs (list): list of win probability
        values relative to the home team
    @param times (list): list of times at which
        the win probability values are calculated
    @param diff (list): list of score differentials
        relative to the home team

    Returns:

        - times (list): list of times at which
        the win probability values are calculated
        - probs_home (list): list of win probability
        values relative to the home team
        - probs_away (list): list of win probability
        values relative to the away team
    """

    probs_home = [0.5] + probs
    probs_away = [1 - x for x in probs_home]

    times, probs_home, probs_away = zip(*sorted(zip(times, probs_home, probs_away)))
    probs_home = list(probs_home)
    probs_away = list(probs_away)
    times = list(times)

    home_won = int(diff[-1]>0)
    probs_home[0] = float(home_won)
    probs_away[0] = float(1-home_won)

    return times, probs_home, probs_away