def GetMaxValueFromScaffold(pos_to_Zscr_d):
    """
    Args:
       pos_to_Zscr_d: (d)
           mean: (float)
           SD: (float)
           pos_to_Zscr_l: list<value_tuple>
               value_tuple: (list) [position (int), ZScr_val (float)]

    Returns:
        [loc (int), value (int), ZScr_val (float)]
    """

    max_z = -1
    max_loc = -1

    cvs = pos_to_Zscr_d["pos_to_Zscr_l"]
    for i in range(len(cvs)):
        if cvs[i][1] > max_z:
            max_z = cvs[i][1]
            max_loc = cvs[i][0]

    value = pos_to_Zscr_d["mean"] + (pos_to_Zscr_d["SD"] * max_z)

    return [max_loc, value, max_z]