def splits_to_ms(splitTimes, taxa, reps, path_to_ms, y, prefix, admix=None):
    """
    Converts inputs into a call to ms
    TODO: Add introgression
    """
    nsamples = len(splitTimes) + 1
    call = path_to_ms + ' ' + str(nsamples) + ' ' + str(reps
        ) + ' -T -I ' + str(nsamples)
    for i in range(0, nsamples):
        call += ' 1'
    for x, split in enumerate(splitTimes):
        call += ' -ej ' + str(split) + ' ' + str(taxa[x][0]) + ' ' + str(taxa
            [x][1])
    if admix is not None:
        call += ' -es ' + admix[0] + ' ' + admix[1
            ] + ' ' + '1' + ' -ej ' + admix[0] + ' ' + str(nsamples + 1
            ) + ' ' + admix[2]
    if admix is not None:
        call += ' | tail -n +4 | grep -v // > ' + prefix + '.trees' + str(y
            ) + '.tmp'
    else:
        call += ' | tail -n +4 | grep -v // > ' + prefix + '.trees' + str(y
            ) + '.tmp'
    return call
