[gmx-users] How to use make_ndx in script to combine 2 groups

Jia Xu xujia.ruc at gmail.com
Thu Nov 20 01:22:38 CET 2014


Hello,

    Shell script can do this. Multiple lines can be redirected by a here
document.  You can make a script including the lines below, or just type
these lines in shell terminal

    make_ndx -f xyz.gro -o index.ndx << EOF
       group1 | group4
       q
       EOF

    A simpler way to do this is:

    echo "group1 | group4 \n q" | make_ndx -f xyz.gro -o index.ndx

Jia

On Wed, Nov 19, 2014 at 4:47 PM, Agnivo Gosai <agnivogromacs14 at gmail.com>
wrote:

> Hello Users
>
> I plan to use make_ndx in a script for passing it on to grompp by combining
> two groups of molecules in my system.
>
> When running interactively I use make_ndx  -f xyz.gro -o index.ndx
> Choose groups :
>
> group1 | group 4
>
> hit enter
>
> type q
>
> hit enter
>
> I was thinking of putting these set of interactions on a script. Can I type
> group1 , group4 , | , q on a .txt file and pass it onto make_ndx in the
> script. I have not seen myself , but I am speculating. Please bear with my
> ignorance.
>
> Thanks & Regards
> Agnivo Gosai
> Grad Student, Iowa State University.
> --
> 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-request at gromacs.org.
>


More information about the gromacs.org_gmx-users mailing list