def write_ind(out, triple, outfile):
    """
    Write the current output dictionary from test_individuals()
    to the file passed as an argument to the function.
    """
    for k, v in out.items():
        print(triple[0], '\t', k, '\t', triple[2], '\t', sep='', end='',
            file=outfile)
        print(v['Zscore'], '\t', sep='', end='', file=outfile)
        print(v['Pvalue'], '\t', sep='', end='', file=outfile)
        print(v['Gamma'], '\t', sep='', end='', file=outfile)
        print(v['AAAA'], '\t', sep='', end='', file=outfile)
        print(v['AAAB'], '\t', sep='', end='', file=outfile)
        print(v['AABA'], '\t', sep='', end='', file=outfile)
        print(v['AABB'], '\t', sep='', end='', file=outfile)
        print(v['AABC'], '\t', sep='', end='', file=outfile)
        print(v['ABAA'], '\t', sep='', end='', file=outfile)
        print(v['ABAB'], '\t', sep='', end='', file=outfile)
        print(v['ABAC'], '\t', sep='', end='', file=outfile)
        print(v['ABBA'], '\t', sep='', end='', file=outfile)
        print(v['BAAA'], '\t', sep='', end='', file=outfile)
        print(v['ABBC'], '\t', sep='', end='', file=outfile)
        print(v['CABC'], '\t', sep='', end='', file=outfile)
        print(v['BACA'], '\t', sep='', end='', file=outfile)
        print(v['BCAA'], '\t', sep='', end='', file=outfile)
        print(v['ABCD'], '\n', sep='', end='', file=outfile)
