Selection of the amino acids for PCA calculations

Dear Gromacs users !

I am performing PCA of a nanosecond trajectory calculated for dimeric protein.

Would it be possible to select automatically (without definition of amino acid numbers in the ndx file) the atomic subset corresponded to:

  1. C alpha atoms of the amino acids that are in the contact to the ligand residue ?
  2. C alpha atoms of the amino acids belong to Alpha helixes or B-stands (excluding loops) ?

Many thanks in advance!

Cheers

James