Re: Get number of timesteps from DCD via script

From: Chris Harrison (charris5_at_gmail.com)
Date: Mon Feb 07 2011 - 12:34:25 CST

Load the trajectory in VMD and under the Extensions menu, open the
tkConsole. In the tkConsole, to get the data you're interested in:

> 1) overall number of coordinate sets (timesteps)
Load the trajectory in VMD and under the Extensions menu, open the
tkConsole. In the tkConsole, type "mol info top get frames"
Alternatively, you can use the catdcd program:
http://www.ks.uiuc.edu/Development/MDTools/catdcd/
and at the commandline, type "catdcd dcdFileName", which
will number the number of frames in the dcd.

> 2) write out frequency (dcdfreq)
You'll unfortunately need to acquire this by opening the original namd
config file used to run the simulation.

> 3) first time step in dcd
I don't believe we output this data into the dcd. In future
trajectory formats developed, we could be make this data available

> 4) last time step in dcd
Same answer as #4, or: firstTimeStepValue + (numberTimeSteps *
dcdfreqValue) ;)

Best,
Chris

--
Chris Harrison, Ph.D.
Theoretical and Computational Biophysics Group
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave., Urbana, IL 61801
char_at_ks.uiuc.edu                          Voice: 217-244-1733
http://www.ks.uiuc.edu/~char              Fax:   217-244-6078
Bjoern Olausson <namdlist_at_googlemail.com> writes:
> Date: Mon, 7 Feb 2011 13:52:39 +0100
> From: Bjoern Olausson <namdlist_at_googlemail.com>
> To: "MailingList, NAMD" <namd-l_at_ks.uiuc.edu>
> Subject: namd-l: Get number of timesteps from DCD via script
> Reply-To: namdlist_at_gmail.com
> User-Agent: KMail/1.13.5 (Linux/2.6.36.2-unpatched; KDE/4.4.5; x86_64; ; )
> 
> Hi,
> 
> I started to use some TCL-Scripting with NAMD for pair interaction energy 
> calculations.
> 
> To make things more convenient and more generic, I was wondering if it is 
> possible to get some of these information from the DCD:
> 1) overall number of coordinate sets (timesteps)
> 2) write out frequency (dcdfreq)
> 3) first time step in dcd
> 4) last time step in dcd
> 
> well, 1) could be obtained from 3) and 4) but why the detour if there could be 
> a direct way ;-)
> 
> And if someone could recommend a good TCL and/or NAMD scripting tutorial, 
> please let me know.
> 
> Thanks a lot.
> Bjoern
> 
> 
> -- 
> Bjoern Olausson
> Martin-Luther-Universität Halle-Wittenberg 
> Fachbereich Biochemie/Biotechnologie
> Kurt-Mothes-Str. 3
> 06120 Halle/Saale
> 
> Phone: +49-345-55-24942

This archive was generated by hypermail 2.1.6 : Wed Feb 29 2012 - 15:56:36 CST