<html><head><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;" class="">Here is an example ChimeraX Python script to open an atomic structure and a map, rotate and save an image. All it does is run the equivalent ChimeraX commands. Saving an image can only be done with the GUI or on Linux with the --offscreen startup flag. If I don't need to save an image I could run it without a gui<div class=""><div class=""><br class=""></div><div class=""><span class="Apple-tab-span" style="white-space:pre"> </span>chimerax --nogui batch.py</div><div class=""><br class=""></div><div class="">Python code below.</div><div class=""><br class=""></div><div class=""> Tom</div><div class=""><br class=""></div><div class=""><br class=""></div><div class=""><div class=""><div class=""># Open a PDB file and an XPLOR map file, rotate and save an image.</div><div class=""><br class=""></div><div class="">from chimerax.core.commands import run</div><div class=""><br class=""></div><div class="">pdb_path = '~/Downloads/ChimeraX/PDB/1grl.cif'</div><div class="">map_path = '~/Downloads/ChimeraX/EMDB/emd_1080.map'</div><div class=""><br class=""></div><div class="">models = run(session, f'open {pdb_path}')</div><div class="">m = models[0]</div><div class="">print(f'Opened {m.name} with {m.num_atoms} atoms') </div><div class=""><br class=""></div><div class="">maps = run(session, f'open {map_path}')</div><div class="">v = maps[0]</div><div class="">sx,sy,sz = v.data.size</div><div class="">print(f'Opened {v.name} with grid size {sx}, {sy}, {sz}') </div><div class=""><br class=""></div><div class="">run(session, 'turn y 90')</div><div class="">run(session, 'save image.png')</div></div><div class=""><br class=""></div></div><div class=""><br class=""></div><div class=""></div></div></body></html>