# [gmx-users] g_sham

Smith, Micholas D. smithmd at ornl.gov
Fri Aug 7 14:20:16 CEST 2015

```>1. Is it feasible to obtain free energy landscape (FEL) from a 2D
>projection (using g_anaeig) of  index groups (say some loop's atoms) which
>are used for the least squares fit in g_covar and then selecting index
>group of elements that corresponds to the eigenvectors (say Prot-masses)?
>Or,
>Should I calculate covariance (g_covar) of my concerned loops separately
>and then should I go for g_sham?

I am not sure if I understand, however, I think I may be able to help a litttle. g_sham is just a histograming program that inverts the resulting histogram into energy space, so using a 2D projection is a legitimate use. Indeed what you are trying to do is very similar to the steps used in dPCA (see: http://www.gromacs.org/Documentation/How-tos/Dihedral_PCA?highlight=dihedral+pca ).

>2. Is there any representative way to get the exact time point for the
>corresponding minima obtained from g_sham?

If you have the time series for each of the coordinates used in the 2D projection you just need to scan through the 2D timeseries for values that match the minimia. e.g. If in the g_sham a minima is at coordinates (10,10) than you need to scan through the timeseries of your coordinates:
time coord1 coord2
1         0        0
2         1       10
3         40     400
4        10        25
.......
.......
5000  10     10
.....
6000   10    10
.....
988908   10  10
....

where frames 988908, 5000, and 6000 are the ones you are looking for. You could extract these with

awk -v x=coord1min -v y=coord2min 'BEGIN{while(getline < "yourfile_first_coordinate_here.xvg"){if(\$0!~/#/&&\$0!~/@/&&\$0!~/&/){a[\$1]=\$2}}{if(\$0!~/#/&&\$0!~/@/&&\$0!~/&/){if(a[\$1]==x&&\$2==\$y){print \$1}}' yourfile_second_coordinate_here.xvg

where you would provide the x and y coords of the minina where I have coord1min and coord2min.

You may be more interested in getting frames near the minimia and not actually on it, in which case just change the last if-statement as needed.

Hope that helps.

-Micholas

===================
Micholas Dean Smith, PhD.
Post-doctoral Research Associate
University of Tennessee/Oak Ridge National Laboratory
Center for Molecular Biophysics

________________________________________
From: gromacs.org_gmx-users-bounces at maillist.sys.kth.se <gromacs.org_gmx-users-bounces at maillist.sys.kth.se> on behalf of Naba <nabajyoti.goswami at gmail.com>
Sent: Friday, August 07, 2015 12:57 AM
To: gromacs.org_gmx-users at maillist.sys.kth.se
Subject: [gmx-users] g_sham

Dear All,
I searched a lot more things about g_sham in the mailing list and
eventually getting confused with the inputs. Just make me clear about:

1. Is it feasible to obtain free energy landscape (FEL) from a 2D
projection (using g_anaeig) of  index groups (say some loop's atoms) which
are used for the least squares fit in g_covar and then selecting index
group of elements that corresponds to the eigenvectors (say Prot-masses)?
Or,
Should I calculate covariance (g_covar) of my concerned loops separately
and then should I go for g_sham?

2. Is there any representative way to get the exact time point for the
corresponding minima obtained from g_sham?

Thanks for all previous helps...
Naba

Bioinformatics Infrastructure Facility
Department of Animal Biotechnology
College of Veterinary Science
Khanapara,Guwahati 781022
Assam, India
--
Gromacs Users mailing list

* Please search the archive at http://www.gromacs.org/Support/Mailing_Lists/GMX-Users_List before posting!