Re: [AMBER] ptraj closest water

From: George Tzotzos <>
Date: Mon, 18 Jul 2011 18:49:28 +0200

Carlos, Daniel many thanks.

Daniel, I need to compile cpptraj. I shall do so shortly. I'm following your instructions
unless otherwise advised by you.

As concerns my last question (re ptraj scanning mdcrd files not specified in the trajin line), please consider it redundant. I must have been doing something wrong.

Best regards


On Jul 18, 2011, at 6:19 PM, Daniel Roe wrote:

> Hi,
> On Mon, Jul 18, 2011 at 12:00 PM, George Tzotzos <> wrote:
>> Is there a way to produce only one new.pdb file?
> If your intent is to create a single PDB file containing all of your
> frames you can either write a script that will concatenate all of your
> PDB files into a single file separated with MODEL X and ENDMDL
> keywords, or just use cpptraj (this is the default way cpptraj writes
> out PDB files).
> If your intent is to only write 1 frame, you need to specify that in
> your trajin command - numeric arguments are not processed for trajout
> commands:
> trajin prod_2ns.mdcrd 1 1
> trajout test.pdb pdb
> If you want to write out your entire trajectory as netcdf AND write
> only 1 frame of PDB, you need to use cpptraj and the 'onlyframes'
> keyword:
> trajin prod_2ns.mdcrd
> trajout test.pdb pdb onlyframes 1
> trajout prod_closest_WAT_2.mdcrd netcdf
> This will create a PDB file containing only the first frame from
> prod_2ns.mdcrd, as well as the specified output netcdf trajectory
> containing all frames. Note that cpptraj does not use the "solvent"
> command (right now solvent is assumed to be named :WAT so your script
> should still run fine in cpptraj).
>> Furthermore, if the working directory contains other trajectories (e.g. prod_4ns, prod_6ns, etc.), the script scans them all - although they are not specified in the first line of the script. Any suggestions why so?
> This should not happen. Are you executing this as part of a larger
> shell script? The trajin command of ptraj should only process the file
> it is given. If you can, please post your entire ptraj output as an
> attachment.
> Let me know if you have any more questions.
> -Dan
> _______________________________________________
> AMBER mailing list

AMBER mailing list
Received on Mon Jul 18 2011 - 10:00:04 PDT
Custom Search