
Thanks a lot, Eric, I was close. Elaine, I had no idea!!! Thank you very much! Cheers, JD **************************** Dr. Jean-Didier Maréchal Lecturer The Computational Biotechnological Chemistry Team Unitat de Química Física Departament de Química Universitat Autònoma de Barcelona Edifici C.n. 08193 Cerdanyola (Barcelona) Tel: +34.935814936 e-mail: JeanDidier.Marechal@uab.es www: http://g <http://asklipio.qf.uab.es>ent.uab.cat/jdidier<http://ent.uab.es/jdidier> 2013/3/27 Eric Pettersen <pett@cgl.ucsf.edu>
On Mar 27, 2013, at 10:44 AM, Jean-Didier Maréchal wrote:
Hi all,
I have a problem with a prot and it seems that renumbering could help. I'd like to automatically add 230 to the residue number of the aa of my second chain. As I feared, when looping other residue to change res.id.position, my script fails as position can not be modified. How could I do this? Should I delete position and re-create it?
Though you can't modify res.id.position, you *can* overwrite res.identirely. So something like:
from chimera import MolResId for r in residues: r.id = MolResId(r.id.chainId, r.id.position+230, r.id.insertionCode)
--Eric