Utils
cli_align_pdb()
¶
Command-line interface for aligning PDB file.
cli_filter_pdb()
¶
Command-line interface for filtering PDB file lines
cli_merge_pdbs()
¶
Command-line interface for merging PDB files
cli_write_pdb()
¶
Command-line interface for writing PDB from topology and coordinate files.
keep_lines(lines, record_types=('ATOM', 'HETATM', 'TER', 'END'))
¶
parse_atomname(line)
¶
parse_resid(line)
¶
parse_resname(line)
¶
replace_in_pdb_line(line, orig, new, start, stop)
¶
General function to replace parts of a PDB line.
PARAMETER | DESCRIPTION |
---|---|
line |
PDB line.
TYPE:
|
orig |
Original value to check if it exists.
TYPE:
|
new |
If
TYPE:
|
start |
Slice the line starting here to replace.
TYPE:
|
stop |
Slice the line stopping here to replace.
TYPE:
|
run_align_pdb(pdb_path, out_path, selection_str=None)
¶
run_filter_pdb(pdb_path, output_path=None, record_types=None)
¶
Only keep PDB lines that contain specified record types.
PARAMETER | DESCRIPTION |
---|---|
pdb_path |
Path to PDB file.
TYPE:
|
output_path |
Path to save new PDB file. If
TYPE:
|
record_types |
Records to keep in the PDB file. Defaults to
|
RETURNS | DESCRIPTION |
---|---|
list[str]
|
PDB file lines. |
run_merge_pdbs(*pdb_paths, output_path=None)
¶
Merge PDB files. No atoms are removed, only added.
PARAMETER | DESCRIPTION |
---|---|
*pdb_paths |
Paths to PDB files in order of decreasing precedence. We assume the residue indices are consistent across PDB files.
TYPE:
|