1
2
3
4
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
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