Skip to content

Commit

Permalink
fix checkNonstandardResidues
Browse files Browse the repository at this point in the history
  • Loading branch information
jamesmkrieger committed Sep 12, 2024
1 parent e1f4c6f commit 370e561
Showing 1 changed file with 9 additions and 5 deletions.
14 changes: 9 additions & 5 deletions prody/proteins/interactions.py
Original file line number Diff line number Diff line change
Expand Up @@ -235,8 +235,8 @@ def get_energy(pair, source):


def checkNonstandardResidues(atoms):
"""Check whether the atomic structure contain non-standard residues and inform to replace the name
to the standard one to be that non-standard residues are treated in a correct way while computing
"""Check whether the atomic structure contains non-standard residues and inform to replace the name
to the standard one so that non-standard residues are treated in a correct way while computing
interactions.
:arg atoms: an Atomic object from which residues are selected
Expand Down Expand Up @@ -264,9 +264,13 @@ def checkNonstandardResidues(atoms):
if i not in amino_acids:
nonstandard.append(aa_list[nr_i] + str(aa_list_nr[nr_i]))

LOGGER.info('There are several non-standard residues in the structure.')
LOGGER.info('Replace the non-standard name in the PDB file with the equivalent name from the standard one if you want to include them in the interactions.')
LOGGER.info("Residues: {0}.".format(' '.join(nonstandard)))
if len(nonstandard) > 0:
LOGGER.info('There are several non-standard residues in the structure.')
LOGGER.info('Replace the non-standard name in the PDB file with the equivalent name from the standard one if you want to include them in the interactions.')
LOGGER.info("Residues: {0}.".format(' '.join(nonstandard)))
return True

return False


def showPairEnergy(data, **kwargs):
Expand Down

0 comments on commit 370e561

Please sign in to comment.