How to trim .xtc file?

GROMACS version: 2020.5
GROMACS modification: Yes/No

Hello Everyone,

I have a .xtc file with 50000 frames. Is it possible to trim this .xtc file to another .xtc (or any other format) file with 5000 frames? This requires the deletion of some frames periodically.
I wonder if there is any command using gmx or any other script for doing this.
If anyone can help in this regard will be beneficial to me.
Thank you for your time and consideration.


you can try to select your interesting frames by VMD. or use "gmx trjconv -f md.trr -b (*time) -e (^time) -dt (*interval time) -o new.xtc

Thank you for the comment.
I tried -b, -e, -dt on the .xtc file and trimmed to a smaller .xtc file. It worked well.