@follows( buildGeneRegions )
@files( [ ("%s.bed" % x, 
           "%s-expression.annodist" % (x) ) \
              for x in TRACKS_MASTER ] )
def makeAnnotatorDistanceExpression( infile, outfile):
    '''check statistical association between intervals and transcription
    start sites.

    Look at different expression sets.
    '''

    track,workspace = outfile[:-len(".annodist")].split("-")
    
    builder = "gtf-intergenic"
    workspace = TARGET_GENESET

    tmpannotations= PAnnotator.buildAnnotatorDistanceAnnotations( "expression" )
                                                    
    PAnnotator.makeAnnotatorDistance( infile, 
                                      outfile, 
                                      builder,
                                      workspace,
                                      workspace_label = "annotation",
                                      annotations = tmpannotations,
                                      )
    
    os.unlink( tmpannotations )
dataset/ETHPy150Open CGATOxford/cgat/obsolete/pipeline_vitaminD.py/makeAnnotatorDistanceExpression/original