On Sun, Aug 27, 2017 at 5:41 PM, Jewgeni Starikow <
starikow.tfp.uni-karlsruhe.de> wrote:
> Dear all,
>
>
> I have generated an AMBER trajectory with coordinates, velocities and
> forces at every time point. It is readily readable with the standard
> CPPTRAJ routine.
>
> Now, from this point on, how could I write out the relevant data sets
> in some (text or binary) file readable in some straightforward way?
>
> I would greatly appreciate ordering my corresponding output file like
> as follows:
>
> Atom-Nr Time CoordX CoordY CoordZ VelocX VelocY VelocZ
> ForceX ForceY ForceZ
>
> ... ... ... ... ... ... ... ...
> ... ... ...
>
> ...etc., etc., etc. ...
>
> Which set of the CPPTRAJ commands would be most appropriate for the
> above-outlined case?
>
>
hi,
If you know Python, you can use pytraj (cpptraj interface) to write your
own script.
http://amber-md.github.io/pytraj/latest/index.html
import pytraj
traj = pt.iterload('./trunc.nc', top='./system.prmtop')
for frame in traj:
print(frame.time)
print(frame.xyz) # 2D coordinates
print(frame.velocity) # 2D array
print(frame.force) # 2D array
# access atom name
for atom in traj.top.atoms:
print(atom.name)
So on.
Hai
> Respectfully yours,
>
> Evgeni B. Starikov
>
> _______________________________________________
> AMBER mailing list
> AMBER.ambermd.org
> http://lists.ambermd.org/mailman/listinfo/amber
>
_______________________________________________
AMBER mailing list
AMBER.ambermd.org
http://lists.ambermd.org/mailman/listinfo/amber
Received on Sun Aug 27 2017 - 19:30:02 PDT