[gmx-users] Output trajectory frames as separate coordinate files

Peter Mawanga peter.mawanga.lagos at gmail.com
Thu Feb 20 14:31:00 CET 2020


My apologies, this can be achieved easily with the command below:

gmx trjconv -s <reference file, optional> -f <input trajectory file> -n
<index file, optional> -split <mention the trajectory output frequency or
interval (in picoseconds)> -o <desired output prefix>.<output file format>



On Thu, Feb 20, 2020 at 2:15 PM Peter Mawanga <peter.mawanga.lagos at gmail.com>
wrote:

> Hello everyone
>
> Is it possible to output different frames of a .trr trajectory as single
> .gro files without supplying an index (<frame>.ndx) file each time?
>
> In VMD this can be achieved with:
>
> set mol [molinfo top]
> set sel [atomselect $mol all]
> set n [molinfo $mol get numframes]
> for {set i 0} {$i < $n} {incr i} {
>   $sel frame $i
>   $sel update
>   $sel writepdb $i.pdb
>  }
> $sel delete
>
> I am searching for a similar command in Gromacs if feasible where just
> supplying the frame number would be fine or a workaround. Thank you for
> your assistance.
>
> --
> Cheers
> Peter
>


-- 
Cheers
Peter


More information about the gromacs.org_gmx-users mailing list