[chimerax-users] Batch save the image of each chain

Yong Liu liuyongbox at gmail.com
Thu Dec 10 22:29:34 PST 2020


Hi All,
I would like to save the image of each chain in one command. I have wrote following python code, but it is not working. Is anybody know how to fix it?


# save the image of each chain

def batchSave(session):
	chainID_list = info chains 
for x in chainID_list:

chainID = chainID_list.split()

ID = chainID[-1]

save "Desktop/ID.png" width 4000 height 4000 transparentBackground true


def register_command(session):
  from chimerax.core.commands import CmdDesc, register
  desc = CmdDesc()
  register('batchSave', desc, batchSave, logger=session.logger)

register_command(session)

Best,
Yong Liu


More information about the ChimeraX-users mailing list