Changeset 1722:70df6521f068 in orange-bioinformatics for server_update/updatemiRNA.py


Ignore:
Timestamp:
09/17/12 09:53:08 (19 months ago)
Author:
markotoplak
Branch:
default
Message:

updatemiRNA script now also works.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • server_update/updatemiRNA.py

    r1721 r1722  
    214214 
    215215### targets library from TargetScan 
     216 
    216217try: 
    217218    tarscan_url = 'http://www.targetscan.org//vert_50//vert_50_data_download/Conserved_Site_Context_Scores.txt.zip' 
     
    242243    sendMail('Database file of miRNAs not found on: %s' % address) 
    243244      
    244          
    245245if flag: 
    246     orgs_des = dict(zip([re.findall('ID\s*(\S{3,4})-\S*\s*standard;',l)[0] for l in data_webPage.splitlines() if l[0:2]=='ID'],[re.findall('DE\s*(.*)\s\S*.*\sstem[\s|-]loop',l)[0] for l in data_webPage.splitlines() if l[0:2]=='DE'])) 
    247      
     246 
     247    orgs = [re.findall('ID\s*(\S+?)-\S*\s*standard;',l)[0] for l in data_webPage.splitlines() if l[:2]=='ID'] 
     248    des = [re.findall('DE\s*(.*)\s\S*.*\sstem[\s|-]loop',l)[0] for l in data_webPage.splitlines() if l[:2]=='DE'] 
     249 
     250    assert len(orgs) == len(des) 
     251 
     252    orgs_des = dict(zip(orgs, des)) 
     253 
    248254    file_org = get_intoFiles(path,data_webPage) 
    249255     
Note: See TracChangeset for help on using the changeset viewer.