Fundamental methods: pose.residue().total_atom(), pose.atom(#) ?

Member Site Forums PyRosetta PyRosetta – General Fundamental methods: pose.residue().total_atom(), pose.atom(#) ?

Viewing 1 reply thread
  • Author
    • #689

        Are there any methods that can return the total number of atoms in the pose? I am trying to do a simple operation, like shift a peptide some distance along a certain vector, and find myself unable to loop over atoms in the simulation.

        Is there a resource that lists all the methods accessible from the Rosetta python library?

      • #4656

          Did you try residue.natoms() and/or residue_type.natoms()? I haven’t looked at the python but that’s the name of the call in C++.

          There is no pose-based all atoms accessor for atoms, you’ll need to use the residue level.

          Separately, as a general rule, you should probably not be looping through atoms and resetting their 3d coordinates. You should instead determine the single DOF in the atom tree you need to change to get the alteration you want and change that instead. For example, you’d alter the jump connecting the peptide to (whatever), rather than altering the positions of each atom in the peptide.

      Viewing 1 reply thread
      • You must be logged in to reply to this topic.