Changeset 1805:c2e4880abd58 in orange-bioinformatics


Ignore:
Timestamp:
05/23/13 16:16:20 (11 months ago)
Author:
Flashpoint <vid.flashpoint@…>
Branch:
default
Message:

Added functionality to obiGeneSets.py to remove locally stored gene sets. Created a prototype widget OWtest.py to store and remove own gene sets. The front-end still needs work

File:
1 edited

Legend:

Unmodified
Added
Removed
  • _bioinformatics/obiGeneSets.py

    r1798 r1805  
    143143 
    144144    go_sets = obimiRNA.get_GO(mirnas, annotations, enrichment=enrichment, pval=pval, goSwitch=False) 
    145     print go_sets 
    146145 
    147146    go_sets = obimiRNA.filter_GO(go_sets, annotations, treshold=treshold) 
     
    224223    gs_files = filter(is_genesets_file, os.listdir(pth)) 
    225224    return [ filename_parse(fn) + (True,) for fn in gs_files ] 
     225 
     226def remove_local(gene_set): 
     227    """ Removes a given gene set from the local repository. """ 
     228    pth = local_path() 
     229    gs_files = filter(is_genesets_file, os.listdir(pth))  
     230    for setfile in gs_files: 
     231        if setfile.__contains__(gene_set): 
     232            setBgone = os.path.join(pth, setfile) 
     233            os.remove(setBgone)  
    226234 
    227235def list_serverfiles_from_flist(flist): 
     
    414422 
    415423if __name__ == "__main__": 
    416     print reactomePathwaysGeneSets() 
    417     exit() 
    418424    rsf = orngServerFiles.ServerFiles(username=sys.argv[1], password=sys.argv[2]) 
    419425    upload_genesets(rsf) 
Note: See TracChangeset for help on using the changeset viewer.