Mercurial > repos > guerler > springsuite
comparison spring_map.py @ 38:80a4b98121b6 draft
"planemo upload commit 22cd6b0fa88ce0ddc4052beab306f5ba10754f12"
author | guerler |
---|---|
date | Wed, 25 Nov 2020 17:38:24 +0000 |
parents | 0be0af9e695d |
children | 172398348efd |
comparison
equal
deleted
inserted
replaced
37:0be0af9e695d | 38:80a4b98121b6 |
---|---|
6 from spring_package.Molecule import Molecule | 6 from spring_package.Molecule import Molecule |
7 | 7 |
8 | 8 |
9 def getId(line): | 9 def getId(line): |
10 line = line.strip() | 10 line = line.strip() |
11 if len(line) != 6 or line[4:5] != "_": | |
12 raise Exception("Invalid list entry (`PDB_CHAIN`): %s." % line) | |
11 return line[:4].upper() + line[4:6] | 13 return line[:4].upper() + line[4:6] |
12 | 14 |
13 | 15 |
14 def getPDB(line, args): | 16 def getPDB(line, args): |
15 pdb = line[:4].lower() | 17 pdb = line[:4].lower() |
129 output_file.write("%s\n" % entry) | 131 output_file.write("%s\n" % entry) |
130 | 132 |
131 | 133 |
132 if __name__ == "__main__": | 134 if __name__ == "__main__": |
133 parser = argparse.ArgumentParser(description='Maps binding partners to template library') | 135 parser = argparse.ArgumentParser(description='Maps binding partners to template library') |
134 parser.add_argument('-l', '--list', help='List of template entries [PDB_CHAIN]', required=True) | 136 parser.add_argument('-l', '--list', help='List of template entries `PDB_CHAIN`', required=True) |
135 parser.add_argument('-i', '--index', help='PDB Database Index file (dbkit_index)', required=True) | 137 parser.add_argument('-i', '--index', help='PDB Database Index file (dbkit_index)', required=True) |
136 parser.add_argument('-d', '--database', help='PDB Database files (dbkit)', required=True) | 138 parser.add_argument('-d', '--database', help='PDB Database files (dbkit)', required=True) |
137 parser.add_argument('-c', '--cross', help='Cross reference (unmapped)', required=True) | 139 parser.add_argument('-c', '--cross', help='Cross reference (unmapped)', required=True) |
138 parser.add_argument('-o', '--output', help='Cross reference', required=True) | 140 parser.add_argument('-o', '--output', help='Cross reference', required=True) |
139 parser.add_argument('-g', '--log', help='Log File', required=True) | 141 parser.add_argument('-g', '--log', help='Log File', required=True) |