Rename an object in PyMOL

Long time ago since my last blog post… maybe I should just write the small things down. For my PhD, I’m currently working with PyMOL and was wondering how to rename an object there. So I googled searched for “pymol rename object” and did not find the proper solution on the first page. But there is one. Maybe this post will show up for the next one searching for “pymol rename object”.

Just use the command set_name, as it is described in the PyMOL wiki:

set_name old_name, new_name