コード例 #1
0
ファイル: preQC.py プロジェクト: grbot/tc9
def venn(bfile,):

    cmd = "cat %s.bim | awk '{if($1>=1&&$1<=22) print $2}' | sort" %(bfile)
    cmd += " > autosomal.SNPs"
    execmd(cmd)

    for fn_intersection in (None,'autosomal.SNPs'):

        if fn_intersection == 'autosomal.SNPs':
            suffix='%s_autosomal' %(os.path.basename(bfile))
        else:
            suffix='%s' %(os.path.basename(bfile))

        gnuplot.venn4(
            0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
            fn1='bim_not_strand.SNPs',
            fn2='mismatches.SNPs',
            fn3='miss.SNPs',
            fn4='multiple.SNPs',
            fn_intersection=fn_intersection,
            text1='unique to bim file (not in strand file)',
            text2='position mismatches', ## incl. unplaced and allele mismatches (i.e. Ins/Del)
            text3='miss file',
            text4='multiple file',
            suffix=suffix,
            bool_remove=True,
            bool_sorted=False,
            )

    os.remove('autosomal.SNPs')

    return
コード例 #2
0
ファイル: preQC.py プロジェクト: tommycarstensen/tc9
def venn(bfile, ):

    cmd = "cat %s.bim | awk '{if($1>=1&&$1<=22) print $2}' | sort" % (bfile)
    cmd += " > autosomal.SNPs"
    execmd(cmd)

    for fn_intersection in (None, 'autosomal.SNPs'):

        if fn_intersection == 'autosomal.SNPs':
            suffix = '%s_autosomal' % (os.path.basename(bfile))
        else:
            suffix = '%s' % (os.path.basename(bfile))

        gnuplot.venn4(
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            0,
            fn1='bim_not_strand.SNPs',
            fn2='mismatches.SNPs',
            fn3='miss.SNPs',
            fn4='multiple.SNPs',
            fn_intersection=fn_intersection,
            text1='unique to bim file (not in strand file)',
            text2=
            'position mismatches',  ## incl. unplaced and allele mismatches (i.e. Ins/Del)
            text3='miss file',
            text4='multiple file',
            suffix=suffix,
            bool_remove=True,
            bool_sorted=False,
        )

    os.remove('autosomal.SNPs')

    return
コード例 #3
0
ファイル: QC_uganda_preQC.py プロジェクト: js29/tc9
def venn(bfile,):

    cmd = "cat %s.bim | awk '{if($1>=1&&$1<=22) print $2}' | sort > autosomal.SNPs" %(bfile)
    execmd(cmd)

    gnuplot.venn4(
        0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,
        fn1='bim_not_strand.SNPs',
        fn2='mismatches.SNPs',
        fn3='miss.SNPs',
        fn4='multiple.SNPs',
        fn_intersection='autosomal.SNPs',
        text1='unique to bim file',
        text2='position mismatches', ## incl. unplaced and allele mismatches (i.e. Ins/Del)
        text3='miss file',
        text4='multiple file',
        suffix='%s' %(bfile),
        )

    os.remove('autosomal.SNPs')

    return
コード例 #4
0
def venn(bfile, ):

    cmd = "cat %s.bim | awk '{if($1>=1&&$1<=22) print $2}' | sort > autosomal.SNPs" % (
        bfile)
    execmd(cmd)

    gnuplot.venn4(
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        0,
        fn1='bim_not_strand.SNPs',
        fn2='mismatches.SNPs',
        fn3='miss.SNPs',
        fn4='multiple.SNPs',
        fn_intersection='autosomal.SNPs',
        text1='unique to bim file',
        text2=
        'position mismatches',  ## incl. unplaced and allele mismatches (i.e. Ins/Del)
        text3='miss file',
        text4='multiple file',
        suffix='%s' % (bfile),
    )

    os.remove('autosomal.SNPs')

    return