# Creating a group for RMSD analysis

**URL:** <https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553>\
**Category:** User discussions\
**Created:** [January 11, 2023, 9:01pm UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553 "2023-01-11T21:01:58Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![Hanoriega](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hanoriega/32/1562_2.png) [@Hanoriega](https://gromacs.bioexcel.eu/u/Hanoriega)\
**Post date:** [January 11, 2023, 9:01pm UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/1 "2023-01-11T21:01:58Z")

</div>

GROMACS version:  
GROMACS modification: Yes/No  
Here post your question  
GROMACS: gmx rms, version 2020.1-Ubuntu-2020.1-1

I am doing the RMSD analysis of a protein, and would like to include specific domains such as a number of residues for beta sheet/strands, alpha helix, pore region, etc. How would I go about that to create a special group with these specific domains using the residue numbers? Is this possible?

Thank you,  
Heather

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [January 12, 2023, 4:24am UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/2 "2023-01-12T04:24:27Z")

</div>

Via `make_ndx`, you can select stretches of residues, i.e.

```auto
r 1-50 | r 76-90 | r 101-125

```

---

<div class="post-metadata">

**Author:** ![Hanoriega](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hanoriega/32/1562_2.png) [@Hanoriega](https://gromacs.bioexcel.eu/u/Hanoriega)\
**Post date:** [January 12, 2023, 5:04am UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/3 "2023-01-12T05:04:36Z")

</div>

ok, so just to clarify for command. I could do:

gmx make\_ndx -f md\_0\_1.gro r 1-50 | r 76-90 | r 101-125 -o index.ndx

gmx rms -s md\_0\_1.tpr -f md\_0\_1.xtc -n index.ndx -o residues.xvg

?? I am still learning, thanks in advance.

---

<div class="post-metadata">

**Author:** ![Hanoriega](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/hanoriega/32/1562_2.png) [@Hanoriega](https://gromacs.bioexcel.eu/u/Hanoriega)\
**Post date:** [January 12, 2023, 2:25pm UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/4 "2023-01-12T14:25:34Z")

</div>

or do I do:

gmx make\_ndx -f md\_0\_1.gro -o index.ndx

default selection screen appears…then I enter r 1-50 | r 76-90 | r 101-125 ??

and then continue with the gmx rms?

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [January 12, 2023, 2:42pm UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/5 "2023-01-12T14:42:59Z")

</div>

> [@Hanoriega](#):
>
> gmx make\_ndx -f md\_0\_1.gro -o index.ndx
> 
> default selection screen appears…then I enter r 1-50 | r 76-90 | r 101-125 ??

Yes, this is the correct approach. `make_ndx` is an interactive program. Supply whatever residue numbers you need. Type `help` at the prompt to see example syntax.

---

<div class="post-metadata">

**Author:** ![shivam1](https://avatars.discourse-cdn.com/v4/letter/s/b3f665/32.png) [@shivam1](https://gromacs.bioexcel.eu/u/shivam1)\
**Post date:** [February 2, 2023, 1:17am UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/6 "2023-02-02T01:17:27Z")

</div>

> [@jalemkul](#):
>
> you can select stretches of residues, i.e.

> [@jalemkul](#):
>
> Via `make_ndx`, you can select stretches of residues, i.e.
> 
> ```auto
> r 1-50 | r 76-90 | r 101-125
> 
> ```

A follow up query, If there are more than 1 chain in the system, how to select residues for the indexing purpose?  
for say, I want to make index of ChainA, ChainB and ChainC for residues 1-10, 100-110 and 85-95 respectively. What should be the input for the `gmx make_ndx -f MD.gro -o index.ndx`?

Thanks

---

<div class="post-metadata">

**Author:** ![jalemkul](https://dub1.discourse-cdn.com/flex017/user_avatar/gromacs.bioexcel.eu/jalemkul/32/18_2.png) [@jalemkul](https://gromacs.bioexcel.eu/u/jalemkul)\
**Post date:** [February 9, 2023, 6:29pm UTC](https://gromacs.bioexcel.eu/t/creating-a-group-for-rmsd-analysis/5553/7 "2023-02-09T18:29:03Z")

</div>

You can select by chain if you supply a PDB file that contains suitable chain identifiers in it. Such information isn’t present in other GROMACS formats (except perhaps `.tpr`, if it was generated from a PDB file with chains identified).
