dccm 'grpby' option question

Issue #777 new
Hossain Shadman created an issue

Dear Bio3d team,

I have a question. I can’t find an answer to this; if its already been answered please point me in the right direction.

I have a trajectory file for a single protein 33 residues long. I calculated dccm using the below input code: (noh refers to index selection to exclude hydrogens, pdb refers to a pdb file)

cij<-dccm(trj[,noh$xyz],grpby=pdb$atom[noh$atom,'resno'])

and compared it to the result obtained by below code:

cij<-dccm(trj[,noh$xyz])

the bottom code gives me an atom-by-atom correlation whereas the top code gives me residue-by-residue correlation. Please correct me if i’m wrong, but it seems that the ‘grpby’ option just picks the highest atom-atom correlation value between a pair of residues and labels it as the residue-residue correlation value. So for example, if we have two residues A and B. The atom-atom correlation values for residues A and B are all 0 except one atom pair which has a correlation value 1. The ‘grpby’ option then lists 1 as the correlation value for residues A and B (i.e. it just picks the highest atom-atom correlation value).

Can someone explain to me the rationale behind this? Is it not better to pick an average instead of the highest value? Or am i missing something and i can adjust ‘grpby’ to pick an average value if i wanted to? Just want to know your thoughts.

Thank you

Comments (1)

  1. Xinqiu Yao

    Hi Hossain,

    This is a good question. The “maximum” scheme is (more or less) to mimic the popular method to define residue-residue contact (where we take the minimum atomic distance and apply a threshold to see if the residues are in contact or not). To my opinion, taking the maximum might be more robust (for example, independent of residue size). But, of course, we cannot exclude other ways to group residue atoms, such as taking the average.

    Currently, the dccm() function only supports ‘maximum'. To use ‘average’, you need to either modify the code, or calculate it from the atom wise correlation matrix (which shouldn’t be too difficult if you are familiar with R). Let me know if you need any helps.

  2. Log in to comment