How to compute energies of individual proteins in a system using GROMACS gmx mdrun rerun?

I have a system with two proteins. I want to compute the energies of these proteins separately. So, I create two separate groups, say, Prot-1 and Prot-2, and add these to my rerun mdp file as energygrps. However, when I perform gmx energy on the rerun.edr file, any energy term associated with Prot-2 returns 0. Prot-1 returns energy values for the total protein system (i.e. for both proteins). I am not sure what is going wrong here. Any suggestion is highly appreciated.

You can only compute such a quantity by using convert-tpr to strip out the coordinates of interest, then do the same to the trajectory with trjconv, and apply mdrun -rerun on these subset trajectories. Note that the energy of a protein is a totally meaningless quantity, so I don’t recommend doing this.

Thanks for the advice, Justin.