Names
cli_replace_resnames()
¶
Command-line interface for renaming residues.
cli_unify_water_labels()
¶
Command-line interface for unifying water residue and atom names.
modify_lines(pdb_lines, fn_process, fn_args, fn_filter=None, include=None, exclude=None)
¶
replace_atom_names(pdb_lines, orig_atom_name, new_atom_name)
¶
replace_residue_names(pdb_lines, orig_resname, new_resname, fn_filter=None, include=None, exclude=None)
¶
Replace all instances of residue names with another.
PARAMETER | DESCRIPTION |
---|---|
pdb_lines |
List of lines in the PDB file. |
orig_resname |
Original residue name to replace.
TYPE:
|
new_resname |
New residue name.
TYPE:
|
fn_filter |
Filter function to parse part of a line to see if it is in |
include |
Only process lines where the result of |
exclude |
Do not process lines where the result of |
RETURNS | DESCRIPTION |
---|---|
list[str]
|
PDB lines with replace residue names. |
run_replace_resnames(pdb_path, resname_map, output_path=None, fn_filter=None, include=None, exclude=None)
¶
Replace residue names.
PARAMETER | DESCRIPTION |
---|---|
pdb_path |
Path to PDB file.
TYPE:
|
resname_map |
Original (key) and new (value) mapping of residue names to change. |
output_path |
Path to save new PDB file. If
TYPE:
|
fn_filter |
Filter function to parse part of a line to see if it is in |
include |
Only process lines where the result of |
exclude |
Do not process lines where the result of |
RETURNS | DESCRIPTION |
---|---|
list[str]
|
PDB lines with changed residues. |
run_unify_water_labels(pdb_path, atom_map=None, water_resname='WAT', water_atomnames=None, output_path=None)
¶
Ensure that water molecule atom names are O
, H1
, and H2
.
Warning
This has not been tested yet.
PARAMETER | DESCRIPTION |
---|---|
pdb_path |
Path to PDB file.
TYPE:
|
atom_map |
Water atom mappings for |
water_atomnames |
Specifies what water atom names are eligible for replacement.
If |
water_resname |
Residue name of the water molecules.
TYPE:
|
output_path |
Path to save new PDB file. If
TYPE:
|
RETURNS | DESCRIPTION |
---|---|
Iterable[str]
|
PDB lines with changed residues. |