Pairwise distance covariance is calculated as the distance between the C-alpha atoms of protein residues for indexes i and j with respect to the average calculated over a trajectory.
The python dependencies required are:
pip install Cython matplotlib mdtraj
Compile the distance.pyx
file as:
python setup.py build_ext --inplace
The following generates a heatmap plot using data from two separate trajectories:
python plot_distance_2d.py $WT_DIR/distance_matrix.dat $MUTANT_DIR/distance_matrix.dat