import csv


def parseSampleFile(samplefile):
    """
    get list of samples to keep if samplefile supplied

    """

    # f = open(args.input, 'r', encoding = "ISO-8859-1")
    f = open(samplefile, 'r', encoding="utf-8")
    reader = csv.DictReader(f, delimiter='\t')
    keep_samples = []
    for row in reader:
        keep_samples.append(row['ID'])

    return keep_samples