Hi, No. gmx select will write index groups that could implement a dynamic selection, but trjconv can't do anything sensible with it. You'd have to split the trajectory into a file per frame and match the index group to the file to get the selection into a new file. Even if trjconv was smart enough, you'd also need to use a trajectory format and downstream tools that were about to be flexible about the number of atoms (which is typically not the case)... In principle, our TNG format is able to be flexible, but there's a lot of infrastructure work if people would actually write such files and expect to read them and have everything work well. Better to work on tools that can use the dynamic selection without needing to serialize and de-serialize files (and the new GROMACS analysis framework has such support, but we don't have much funding for implementing / porting tools to it).
Mark On Thu, Jun 8, 2017 at 10:48 AM João Henriques <joao.m.a.henriq...@gmail.com> wrote: > Hi Mark, > > Does your solution output variable numbers of water molecules per frame? > That is exactly what I've been wanting to do for a while, but with my > solution it becomes very difficult to do so and I usually end up using a > fixed number of closest waters for all frames. > > João > > > > On Thu, Jun 8, 2017 at 10:34 AM, Mark Abraham <mark.j.abra...@gmail.com> > wrote: > > > Hi, > > > > Or gmx select to make an index group for the nearest waters, and gmx > > trjconv to make the subset with the index group. > > > > Mark > > > > On Thu, Jun 8, 2017 at 9:05 AM João Henriques < > > joao.m.a.henriq...@gmail.com> > > wrote: > > > > > Hi, > > > > > > trjorder can reorder the water molecules in each frame according to > their > > > distance to the protein. Then you either manually prune the gro file(s) > > or > > > use an index file to get rid of the extra stuff. I don't know of any > > native > > > tool that does all of this in one step but I may be outdated regarding > > new > > > stuff on gmx 2016. > > > > > > Cheers, > > > João > > > > > > On Jun 8, 2017 2:49 AM, "Jose Borreguero" <borregu...@gmail.com> > wrote: > > > > > > Dear Gromacs users, > > > > > > I'm a newbie with Gromacs. Is there a Gromacs native tool that will > allow > > > me to create a new *.gro file containing the protein and the N closest > > > water molecules to the protein > > > , starting from a system of a solvated protein > > > ? > > > > > > Best, > > > Jose Borreguero > > > -- > > > Gromacs Users mailing list > > > > > > * Please search the archive at http://www.gromacs.org/ > > > Support/Mailing_Lists/GMX-Users_List before posting! > > > > > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists > > > > > > * For (un)subscribe requests visit > > > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or > > send > > > a mail to gmx-users-requ...@gromacs.org. > > > -- > > > Gromacs Users mailing list > > > > > > * Please search the archive at > > > http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before > > > posting! > > > > > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists > > > > > > * For (un)subscribe requests visit > > > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or > > > send a mail to gmx-users-requ...@gromacs.org. > > -- > > Gromacs Users mailing list > > > > * Please search the archive at http://www.gromacs.org/ > > Support/Mailing_Lists/GMX-Users_List before posting! > > > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists > > > > * For (un)subscribe requests visit > > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or > > send a mail to gmx-users-requ...@gromacs.org. > > > -- > Gromacs Users mailing list > > * Please search the archive at > http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before > posting! > > * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists > > * For (un)subscribe requests visit > https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or > send a mail to gmx-users-requ...@gromacs.org. -- Gromacs Users mailing list * Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting! * Can't post? Read http://www.gromacs.org/Support/Mailing_Lists * For (un)subscribe requests visit https://maillist.sys.kth.se/mailman/listinfo/gromacs.org_gmx-users or send a mail to gmx-users-requ...@gromacs.org.