@transform( getCapseqGeneTSSOverlapCount, suffix(".gene_tss.overlap.count"), ".gene_tss.overlap.count.load")
def loadCapseqGeneTSSOverlapCount(infile, outfile):
    header = "track,intervals"
    track = P.snip( os.path.basename( infile), ".gene_tss.overlap.count" )
    geneset_name = PARAMS["geneset_name"]
    statement = '''cat %(infile)s | python %(scriptsdir)s/csv2db.py
                        --database=%(database)s
                        --table=%(track)s_%(geneset_name)s_gene_tss_venn
                        --header=%(header)s
                   > %(outfile)s '''
    P.run()
    
############################################################
############################################################
## Section 1c: Annotate CAPseq interval TTS/TTS distance
Load gene TSS Capseq overlap into database
dataset/ETHPy150Open CGATOxford/cgat/obsolete/pipeline_proj007.py/loadCapseqGeneTSSOverlapCount