You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/source/guessing.rst
+9-7Lines changed: 9 additions & 7 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -95,7 +95,7 @@ Whereas most attributes are guessed at the atom, residue, or segment level, gues
95
95
96
96
Specifically, if these connectivity attributes are guessed, they are by default guessed *additively*. Therefore, if bonds and other objects are guessed twice, the bonds of the second guess are added on. Below, we see the number of bonds increase when guessed again with a looser criteria.
97
97
98
-
.. ipython::
98
+
.. ipython::python
99
99
100
100
from MDAnalysis.tests.datafiles importCONECT
101
101
@@ -104,27 +104,31 @@ Specifically, if these connectivity attributes are guessed, they are by default
Moreover, bonds are unique, so if the bonds are guessed again with a same criteria, the guessed bonds doesn't change.
115
117
116
-
.. ipython::
118
+
.. ipython::python
117
119
118
120
u.guess_TopologyAttrs(to_guess=["bonds"], fudge_factor=0.5) # same
119
121
print(len(u.bonds))
120
122
123
+
121
124
However, if you want to forcibly overwrite all existing bonds, angles, dihedrals or impropers, you can pass the object to the ``force_guess`` keyword. This will remove all existing objects of that type before guessing. Below, we see the number of bonds has shrunk when guessed with stricter criteria.
0 commit comments