def mask(args):
    """
    %prog mask meta.tsv data.bin samples.ids STR.ids

    Compute P-values based on meta and data. Write mask.bin and a new meta.tsv
    with updated counts.
    """
    p = OptionParser(mask.__doc__)
    opts, args = p.parse_args(args)

    if len(args) != 4:
        sys.exit(not p.print_help())

    metafile, databin, sampleids, strids = args
    df, m, samples, loci = read_binfile(databin, sampleids, strids)
    sf = pd.read_csv(metafile, index_col=0, sep="\t")
    #print sf[["id", "allele_frequency"]]
    for i, locus in enumerate(loci):
        a = m[:, i]
        print locus, a
        counts = alleles_to_counts(a)
        p_counts = af_to_counts(sf.ix[locus]["allele_frequency"])
        print "before:", counts
        counts.update(p_counts)
        af = counts_to_af(counts)
        print "after:", counts
        if i is not 30:
            return
dataset/ETHPy150Open tanghaibao/jcvi/variation/str.py/mask/operator `>` -> `is not`