ProtoCaller.IO.PDB.Residue module

class ProtoCaller.IO.PDB.Residue.Residue(atoms=None)

Bases: ProtoCaller.IO.PDB.Missing.MissingResidue, ProtoCaller.Utils.ConditionalList.ConditionalList

Represents a single residue in a PDB file.

Parameters

atoms ([ProtoCaller.IO.PDB.Atom.Atom]) – A list of atoms.

resName

Residue name.

Type

str

chainID

Chain identifier.

Type

str

resSeq

Residue sequence number.

Type

int

iCode

Code for insertion of residues.

Type

str

property numberOfAtoms

Returns the number of atoms.

Type

int

purgeAtoms(atoms, mode)

Removes or keeps the selected atoms.

Parameters
  • atoms ([ProtoCaller.IO.PDB.Atom.Atom]) – Atoms to be removed or kept

  • mode (str) – One of “keep” and “discard” - either keeps only the selection or discards the latter.

reNumberAtoms(start=1, custom_serials=None)

Renumbers the atoms.

Parameters
  • start (int, optional) – Initial index.

  • custom_serials ([int] or None, optional) – A list of custom indices. If None, atoms are renumbered sequentially.

property sequence

Returns the single-character code of the amino acid residue.

Type

str