From: Josh Vermaas (
Date: Tue Apr 09 2013 - 09:25:07 CDT

Another option is to run VMD in text mode. Make a simple script
(script.tcl) like this:

mol new psffile.psf
set nowater [atomselect top "not water"]
for { set i 0 } { $i < 70000 } { incr i } {
    animate read dcd dcdfile.dcd beg $i end $i waitfor all
    $sel writepdb $i.pdb
    animate delete

This will go through each frame one by one and write it to its own pdb,
while never keeping more than 1 frame in memory. You can then run it
from the command line with something like:

vmd -dispdev text -e script.tcl (see for more on
using the command line to start vmd, including the extra step required
on windows)


On 04/09/2013 01:12 AM, wrote:
> Hey,
> Consider using ambertools ptraj for instance, which could do the pdb export.
> Best regards.
> Peter
> -----Message d'origine-----
> De : [] De la part de Yarrow Madrona
> Envoyé : mardi 9 avril 2013 01:43
> À : VMD mailing list
> Objet : Re: vmd-l: how to convert dcd to pdbs in command line
> Hello,
> I am trying to convert a dcd to a series of pdb's without opening the VMD GUI. The reason is that I don't have enough ram to store the DCD (70,000
> frames) into memory. VMD always crashes unless I use a truncated DCD. I would like to use all frames since the frames will be analyzed by another software (Caver3.0). Is there a way to tell vmd to write out all PDBs in the command line (preferably without water although I can remove those later)?
> Thank you
> --
> Yarrow Madrona
> Graduate Student
> Molecular Biology and Biochemistry Dept.
> University of California, Irvine
> Natural Sciences I, Rm 2403
> Irvine, CA 92697