
Hello Chimera fans! Is there a way to use chimera for finding hydrogen bonds for tons of molecules? I'm thinking of something like a command line script, which loads a pdb file, fetches the hbonds and writes them to a file. I got around 1000 pdb files and therefore doing everything manually is not an option ;-) greetings, Stefan -- Stefan Bienert Zentrum fuer Bioinformatik Universitaet Hamburg Bundesstrasse 43 20146 Hamburg Germany Email: bienert@zbh.uni-hamburg.de Phone: +49 (40) 42838 7345 Fax: +49 (40) 42838 7332

On May 4, 2007, at 12:45 AM, Stefan Bienert wrote:
Hello Chimera fans!
Is there a way to use chimera for finding hydrogen bonds for tons of molecules? I'm thinking of something like a command line script, which loads a pdb file, fetches the hbonds and writes them to a file. I got around 1000 pdb files and therefore doing everything manually is not an option ;-)
If you don't want to learn/write Python code, the most straightforward way to do this I can think of is to loop through your files in the Unix shell, calling the no-interface version of Chimera for each one. Something like this (if your shell has csh-like syntax, e.g. tcsh): foreach pdb (*.pdb) echo $pdb chimera --nogui $pdb hbonds.com mv hbonds.out $pdb:r.hbonds You would want to be in the directory with your "1000 pdb files" in order for the "*.pdb" to match. The "--nogui" arg to Chimera means don't bring up the user interface. The other two args are the PDB file to open and then a script to run to write the hbonds. The "mv" command moves the hbond info into a name specific to the PDB file (the same name as the PDB file but with ".pdb" changed to ".hbonds"). The hbonds.com script would be something like: hbonds savefile hbonds.out batch true (adding other arguments to taste) If you are willing to use Python then you have the ability to move the loop inside Chimera and thereby only call Chimera once, which will be faster but which might run into issues of memory usage. Regardless, the H-bond-finding code is not terribly fast (it's complex and also written in Python) and will likely takes 10s of seconds per structure, so we're talking about several hours to process that number of files. --Eric Eric Pettersen UCSF Computer Graphics Lab pett@cgl.ucsf.edu http://www.cgl.ucsf.edu

Hello Eric, thank you for the answer to my problem. Is there any documentation of the chimera "--nogui" interface? 10s (or more) per file is no problem, I only have to get the hbonds once and I have a cluster to distribute the computations to. greetings, Stefan -- Stefan Bienert Zentrum fuer Bioinformatik Universitaet Hamburg Bundesstrasse 43 20146 Hamburg Germany Email: bienert@zbh.uni-hamburg.de Phone: +49 (40) 42838 7345 Fax: +49 (40) 42838 7332

Hi Stefan, I know you said in private email later that you found the docs, but for the benefit of other list denizens and future mail-archive searchers, the docs are here: http://www.cgl.ucsf.edu/chimera/docs/UsersGuide/options.html --Eric On May 7, 2007, at 11:09 PM, Stefan Bienert wrote:
Hello Eric,
thank you for the answer to my problem. Is there any documentation of the chimera "--nogui" interface? 10s (or more) per file is no problem, I only have to get the hbonds once and I have a cluster to distribute the computations to.
greetings,
Stefan
-- Stefan Bienert Zentrum fuer Bioinformatik Universitaet Hamburg Bundesstrasse 43 20146 Hamburg Germany
Email: bienert@zbh.uni-hamburg.de Phone: +49 (40) 42838 7345 Fax: +49 (40) 42838 7332
participants (2)
-
Eric Pettersen
-
Stefan Bienert