Hi Catherine, If all the pseudobonds you intend to add are within one structure (call it 's'), then the code would be:
pbg = s.pseudobond_group("name of pseudobond group")
pbg.new_pseudobond(atom1, atom2)
If at least some of the pseudobonds are between structures, then instead:
pbg = session.pb_manager.get_group("name of pseudobond group")
pbg.new_pseudobond(atom1, atom2)
You don't say whether this pseudobond is meant to convey that those CAs are in the same chain but that the structure between them is missing. If so, than you should specifically create "missing structure" pseudobonds, with:
pbg = s.pseudobond_group(s.PBG_MISSING_STRUCTURE)
pbg.new_pseudobond(atom1, atom2)
--Eric
Eric Pettersen
UCSF Computer Graphics Lab
On Jan 24, 2025, at 8:30 AM, Nguyen, Catherine via ChimeraX-users <chimerax-users@cgl.ucsf.edu> wrote: