Package Bio :: Package AlignAce :: Module CompareAceStandalone
[hide private]
[frames] | no frames]

Source Code for Module Bio.AlignAce.CompareAceStandalone

 1  # Copyright 2003 by Bartek Wilczynski.  All rights reserved. 
 2  # This code is part of the Biopython distribution and governed by its 
 3  # license.  Please see the LICENSE file that should have been included 
 4  # as part of this package. 
 5   
 6  """ 
 7   
 8  This module provides code to work with the standalone version of CompareAce,  
 9  for motif comparison 
10   
11  CompareACE homepage: 
12   
13  http://atlas.med.harvard.edu/ 
14   
15  functions: 
16  CompareAce - runs the AlignACE standalone prgram and returns the ApplicationResult object 
17  """ 
18   
19  import os 
20  import string 
21  import re 
22   
23  from Bio import File 
24  from Applications import CompareAceCommandline 
25   
26  import Scanner 
27  import Parser 
28   
29   
30 -def CompareAce( cmd="CompareACE", **keywds):
31 """Runs CompareACE and returns data. 32 33 motif1, motif2 == files containing AlignACE motifs 34 """ 35 36 if not os.path.exists(cmd): 37 raise IOError, "Executable does not exist at %s" % cmd 38 39 CompareCmd = CompareAceCommandline(cmd) 40 41 for (par,val) in keywds.iteritems(): 42 CompareCmd.set_parameter(par,val) 43 44 return CompareCmd.run()
45