[gmx-users] Number/name of the last frame in a trajectory

Mark Abraham Mark.Abraham at anu.edu.au
Wed Jan 11 12:22:58 CET 2012

On 11/01/2012 9:32 PM, Mirco Wahab wrote:
> For checking the "id" of the last frame contained
> in a trajectory, I usually apply ugly command line
> hacks like:
>  echo "0"|trjconv -dump 1e10 -o /tmp/x.gro 2>&1>/dev/null|perl -lne 
> 'print $1 if /t=(\d+)$/'
> which might look awe-inspiring first but is of course tiresome.
> Did I overlook the appropriate trjconv-option for this task?
> Why would you need that? E.g. for saving the last snapshot
> from a trajectory under the name of its time step.

Seems as good a solution as any. Set it up in a script if you use it often.


More information about the gromacs.org_gmx-users mailing list