From: Justin Gullingsrud (justinrocks_at_gmail.com)
Date: Fri Jan 21 2005 - 01:28:42 CST

Hi,

Try adding a "waitfor all" at the end of your "animate write"
instruction. This should force the file handle to be closed after
each file is completed.

Justin

On Fri, 21 Jan 2005 16:05:51 +1300, Ben Roberts
<Ben.P.Roberts_at_vcp.monash.edu.au> wrote:
> Hi all,
>
> I'm trying to write a script to automatically export a DCD trajectory
> file as a series of PDB "frames".
>
> At the moment I am using a "for" loop with an "animate write"
> instruction at each frame. However, this leaves an open filehandle for
> each frame, until the end (where it closes all of the filehandles) or it
> runs out of memory (in which case it crashes), whichever happens first.
>
> Is there a simple and effective "close" command I can use to close the
> files for writing on the fly?
>
> Any advice appreciated.
>
> Thanks in advance,
> Ben
>
> ----------------------------------------------------------------------
> Benjamin P. Roberts, B.Sc.(Hons)
> Ph.D. Student
>
> Department of Medicinal Chemistry
> Victorian College of Pharmacy (Monash University)
> 381 Royal Parade, Parkville VIC 3052, Australia
>
> Phone +61 3 9903 9674 | Fax +61 3 9903 9582 | Mobile +61 401 784 940
> ----------------------------------------------------------------------
>

-- 
The spirit of Plato dies hard.  We have been unable to escape the
philosophical tradition that what we can see and measure in the world
is merely the superficial and imperfect representation of an
underlying reality.
                -- S.J. Gould, "The Mismeasure of Man"