RE: dcd to pdb conversion

From: Claw Isthelaw (clawisthelaw_at_hotmail.com)
Date: Mon Oct 27 2008 - 04:35:26 CDT

Hi. This is more of a VMD question. The following TCL commands load an entire trajectory and it's PSF, then writes out the backbone of every 10th frame to a new PDB file. Each frame is separated by the 'END' keyword.

########################################################
# Load trajectory/PSF
mol new {dhfr_traj.dcd} type {dcd} first 0 last -1 step 1 waitfor 1
mol addfile {dhfr.psf} type {psf} first 0 last -1 step 1000 waitfor 1 top

# Write out every 10th frame of trajectory
animate write pdb {dhfr_traj.pdb} beg 0 end -1 skip 10 sel [atomselect top backbone]
########################################################

By the way, if you know how to do something using the VMD GUI, then an easy way to get the equivalent TCL commands is to start a GUI VMD session and type 'logfile vmd.log' into the vmd console. Then perform operations using the GUI. In this case, you can write out a PDB trajectory by first loading in a DCD along with a PSF. Then select the molecule by highlighting its row in the Main Menu and then under the File menu, choose save coordinates (choose type PDB and atoms backbone). All the TCL equivalent text commands for doing this are logged into the vmd.log file you setup at the start. But you mentioned UNIX, so to do this entirely from UNIX, put the following commands into a scriptfile and run VMD (in text mode for faster results) with:

vmd -dispdev text -e scriptfile.

Jeff Tibbitt

----------------------------------------
> Date: Mon, 27 Oct 2008 10:28:16 +0200
> From: asezerman_at_su.sabanciuniv.edu
> To: namd-l_at_ks.uiuc.edu
> Subject: namd-l: dcd to pdb conversion
>
> Hello,
>
> I would like to save the coordinates of backbone atoms of a protein
> from a trajectory file in pdb format. I am trying to do this by using
> vmd unix command options.I tried to use writepdb command but it was
> unsuccesful as it won't append the frames but overwrite them . Does
> anyone have an idea?
>
> Thanks
>
> Ozlem
>

_________________________________________________________________
You live life beyond your PC. So now Windows goes beyond your PC.
http://clk.atdmt.com/MRT/go/115298556/direct/01/

This archive was generated by hypermail 2.1.6 : Wed Feb 29 2012 - 15:50:01 CST