def d_prime2x2(CF):
    H = (CF[(0, 0)] / (CF[(0, 0)] + CF[(1, 0)]))
    F = (CF[(0, 1)] / (CF[(0, 1)] + CF[(1, 1)]))
    if (H == 1):
        H = (1 - (1 / (2 * (CF[(0, 0)] + CF[(1, 0)]))))
    if (H == 0):
        H = (0 + (1 / (2 * (CF[(0, 0)] + CF[(1, 0)]))))
    if (F == 0):
        F = (0 + (1 / (2 * (CF[(0, 1)] + CF[(1, 1)]))))
    if (F == 1):
        F = (1 - (1 / (2 * (CF[(0, 1)] + CF[(1, 1)]))))
    d = (norm.ppf(H) - norm.ppf(F))
    return d
def d_prime2x2(CF):
    H = (CF[(0, 0)] / (CF[(0, 0)] + CF[(1, 0)]))
    F = (CF[(0, 1)] / (CF[(0, 1)] + CF[(1, 1)]))
    if (H == 1):
        H = (1 - (1 / (2 * (CF[(0, 0)] + CF[(1, 0)]))))
    if (H == 0):
        H = (0 + (1 / (2 * (CF[(0, 0)] + CF[(1, 0)]))))
    if (F == 0):
        F = (0 + (1 / (2 * (CF[(0, 1)] + CF[(1, 1)]))))
    if (F == 1):
        F = (1 - (1 / (2 * (CF[(0, 1)] + CF[(1, 1)]))))
    d = (norm.ppf(H) - norm.ppf(F))
    return d