Post-processing and analysis
Here we assume that you checked the convergence of your system and that all the run ended successfully (no protein unfolding, no other issues). Here we will not focus on convergence, error calculation and metadynamics technical details, considering that such topics are already covered by the Metadynamics tutorial.
Reweighting
After the end of the simulation, we need to reweight our free energy landscape on apt collective variables. As anticipated in the previous step, we will use the distance from the origin of the reference frame $\rho$ and the number of contacts $c$. We thus prepare step-by-step a reweighting script (you can find it in the GitHub folder, called reweight.dat
).
We begin from the reading of the relevant data files (refer to the plumed.dat
file if you do not remember what is contained in them):
Click on the labels of the actions for more information on what each action computes
rhoThe READ action with label rho calculates the following quantities: Quantity | Type | Description |
rho | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
rho: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
cThe READ action with label c calculates the following quantities: Quantity | Type | Description |
c | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
c: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
metadThe READ action with label metad calculates the following quantities: Quantity | Type | Description |
metad.bias | scalar | values from the column labelled metad.bias in the file named results/metad_data.dat |
metad.rbias | scalar | values from the column labelled metad.rbias in the file named results/metad_data.dat |
metad.rct | scalar | values from the column labelled metad.rct in the file named results/metad_data.dat |
metad.work | scalar | values from the column labelled metad.work in the file named results/metad_data.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
metad: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
restr_rmsdThe READ action with label restr_rmsd calculates the following quantities: Quantity | Type | Description |
restr_rmsd.bias | scalar | values from the column labelled restr_rmsd.bias in the file named results/rmsd_restraint.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
restr_rmsd: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
After loading the data, we have to perform the reweighting of the metadynamics potential via the Tiwary-Parrinello estimator. Concurrently, we remove the (almost negligible) contribution of the RMSD restraining, obtaining the final weights for the histogram
Click on the labels of the actions for more information on what each action computes
# --- Click here to reveal hidden parts of input file ----
rhoThe READ action with label rho calculates the following quantities: Quantity | Type | Description |
rho | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
rho: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
cThe READ action with label c calculates the following quantities: Quantity | Type | Description |
c | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
c: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
metadThe READ action with label metad calculates the following quantities: Quantity | Type | Description |
metad.bias | scalar | values from the column labelled metad.bias in the file named results/metad_data.dat |
metad.rbias | scalar | values from the column labelled metad.rbias in the file named results/metad_data.dat |
metad.rct | scalar | values from the column labelled metad.rct in the file named results/metad_data.dat |
metad.work | scalar | values from the column labelled metad.work in the file named results/metad_data.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
metad: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
restr_rmsdThe READ action with label restr_rmsd calculates the following quantities: Quantity | Type | Description |
restr_rmsd.bias | scalar | values from the column labelled restr_rmsd.bias in the file named results/rmsd_restraint.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
restr_rmsd: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
# --- Click here to hide input ---
weightsThe REWEIGHT_BIAS action with label weights calculates the following quantities: Quantity | Type | Description |
weights | scalar | the weight to use for this frame to negate the effect the bias |
: REWEIGHT_BIASCalculate weights for ensemble averages that negate the effect the bias has on the region of phase space explored More details TEMPthe system temperature=300 ARG the biases that must be taken into account when reweighting=metad.rbias,restr_rmsd.bias
Having the weights, we can compute the histogram, considering the data from 200 ns to 1 µs to ignore the out-of-equilibrium portion of the simulation:
Click on the labels of the actions for more information on what each action computes
# --- Click here to reveal hidden parts of input file ----
rhoThe READ action with label rho calculates the following quantities: Quantity | Type | Description |
rho | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
rho: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
cThe READ action with label c calculates the following quantities: Quantity | Type | Description |
c | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
c: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
metadThe READ action with label metad calculates the following quantities: Quantity | Type | Description |
metad.bias | scalar | values from the column labelled metad.bias in the file named results/metad_data.dat |
metad.rbias | scalar | values from the column labelled metad.rbias in the file named results/metad_data.dat |
metad.rct | scalar | values from the column labelled metad.rct in the file named results/metad_data.dat |
metad.work | scalar | values from the column labelled metad.work in the file named results/metad_data.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
metad: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
restr_rmsdThe READ action with label restr_rmsd calculates the following quantities: Quantity | Type | Description |
restr_rmsd.bias | scalar | values from the column labelled restr_rmsd.bias in the file named results/rmsd_restraint.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
restr_rmsd: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
weightsThe REWEIGHT_BIAS action with label weights calculates the following quantities: Quantity | Type | Description |
weights | scalar | the weight to use for this frame to negate the effect the bias |
: REWEIGHT_BIASCalculate weights for ensemble averages that negate the effect the bias has on the region of phase space explored More details TEMPthe system temperature=300 ARG the biases that must be taken into account when reweighting=metad.rbias,restr_rmsd.bias
# --- Click here to hide input ---
HISTOGRAMAccumulate the average probability density along a few CVs from a trajectory. This action is a shortcut and it has hidden defaults. More details ...
ARGthe quantities that are being used to construct the histogram=rho,c
GRID_MIN the lower bounds for the grid=0.,0
GRID_MAX the upper bounds for the grid=3.0,160
GRID_BINthe number of bins for the grid=300,160
KERNEL the kernel function you are using=DISCRETE
LOGWEIGHTSthe logarithm of the quantity to use as the weights when calculating averages=weights
LABELa label for the action so that its output can be referenced in the input to other actions=histoThe HISTOGRAM action with label histo calculates the following quantities: Quantity | Type | Description |
histo | grid | the estimate of the histogram as a function of the argument that was obtained |
UPDATE_FROMOnly update this action from this time=200000
UPDATE_UNTILOnly update this action until this time=1000000
... HISTOGRAM
HISTOGRAMAccumulate the average probability density along a few CVs from a trajectory. This action is a shortcut and uses the defaults shown here. More details ...
ARGthe quantities that are being used to construct the histogram=rho,c
GRID_MIN the lower bounds for the grid=0.,0
GRID_MAX the upper bounds for the grid=3.0,160
GRID_BINthe number of bins for the grid=300,160
KERNEL the kernel function you are using=DISCRETE
LOGWEIGHTSthe logarithm of the quantity to use as the weights when calculating averages=weights
LABELa label for the action so that its output can be referenced in the input to other actions=histo
UPDATE_FROMOnly update this action from this time=200000
UPDATE_UNTILOnly update this action until this time=1000000
NORMALIZATION This controls how the data is normalized it can be set equal to true, false or ndata=ndata STRIDE the frequency with which to store data for averaging=1 CLEAR the frequency with whihc to clear the data that is being averaged=0
... HISTOGRAM
# HISTOGRAM ...
histo_weightThe CONSTANT action with label histo_weight calculates the following quantities: Quantity | Type | Description |
histo_weight | scalar | the constant value that was read from the plumed input |
: ONESCreate a constant vector with all elements equal to one More details SIZEthe number of ones that you would like to create=1
histo_kdeThe KDE action with label histo_kde calculates the following quantities: Quantity | Type | Description |
histo_kde | grid | a function on a grid that was obtained by doing a Kernel Density Estimation using the input arguments |
: KDECreate a histogram from the input scalar/vector/matrix using KDE More details ARGthe label for the value that should be used to construct the histogram=rho,c GRID_MIN the lower bounds for the grid=0.,0 GRID_MAX the upper bounds for the grid=3.0,160 GRID_BINthe number of bins for the grid=300,160 KERNEL the kernel function you are using=DISCRETE
histo_kdepThe CUSTOM action with label histo_kdep calculates the following quantities: Quantity | Type | Description |
histo_kdep | grid | the grid obtained by doing an element-wise application of an arbitrary function to the input grid |
: CUSTOMCalculate a combination of variables using a custom expression. More details ARGthe values input to this function=histo_kde,histo_weight FUNCthe function you wish to evaluate=x*y PERIODICif the output of your function is periodic then you should specify the periodicity of the function=NO
histo_uThe ACCUMULATE action with label histo_u calculates the following quantities: Quantity | Type | Description |
histo_u | grid | a sum calculated from the time series of the input quantity |
: ACCUMULATESum the elements of this value over the course of the trajectory More details ARGthe label of the argument that is being added to on each timestep=histo_kdep STRIDE the frequency with which the data should be collected and added to the quantity being averaged=1 CLEAR the frequency with which to clear all the accumulated data=0 UPDATE_FROMOnly update this action from this time=200000 UPDATE_UNTILOnly update this action until this time=1e+06
histo_nsumThe ACCUMULATE action with label histo_nsum calculates the following quantities: Quantity | Type | Description |
histo_nsum | scalar | a sum calculated from the time series of the input quantity |
: ACCUMULATESum the elements of this value over the course of the trajectory More details ARGthe label of the argument that is being added to on each timestep=histo_weight STRIDE the frequency with which the data should be collected and added to the quantity being averaged=1 CLEAR the frequency with which to clear all the accumulated data=0 UPDATE_FROMOnly update this action from this time=200000 UPDATE_UNTILOnly update this action until this time=1e+06
histoThe CUSTOM action with label histo calculates the following quantities: Quantity | Type | Description |
histo | grid | the grid obtained by doing an element-wise application of an arbitrary function to the input grid |
: CUSTOMCalculate a combination of variables using a custom expression. More details ARGthe values input to this function=histo_u,histo_nsum FUNCthe function you wish to evaluate=x/y PERIODICif the output of your function is periodic then you should specify the periodicity of the function=NO
# --- End of included input ---
This histogram can be converted to a free energy landscape
Click on the labels of the actions for more information on what each action computes
# --- Click here to reveal hidden parts of input file ----
rhoThe READ action with label rho calculates the following quantities: Quantity | Type | Description |
rho | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
rho: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
cThe READ action with label c calculates the following quantities: Quantity | Type | Description |
c | scalar | the value calculated by this action |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
c: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
metadThe READ action with label metad calculates the following quantities: Quantity | Type | Description |
metad.bias | scalar | values from the column labelled metad.bias in the file named results/metad_data.dat |
metad.rbias | scalar | values from the column labelled metad.rbias in the file named results/metad_data.dat |
metad.rct | scalar | values from the column labelled metad.rct in the file named results/metad_data.dat |
metad.work | scalar | values from the column labelled metad.work in the file named results/metad_data.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
metad: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
restr_rmsdThe READ action with label restr_rmsd calculates the following quantities: Quantity | Type | Description |
restr_rmsd.bias | scalar | values from the column labelled restr_rmsd.bias in the file named results/rmsd_restraint.dat |
: READRead quantities from a colvar file. This action has hidden defaults. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
restr_rmsd: READRead quantities from a colvar file. This action uses the defaults shown here. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file STRIDE the frequency with which the file should be read=1 EVERY only read every nth line of the colvar file=1
weightsThe REWEIGHT_BIAS action with label weights calculates the following quantities: Quantity | Type | Description |
weights | scalar | the weight to use for this frame to negate the effect the bias |
: REWEIGHT_BIASCalculate weights for ensemble averages that negate the effect the bias has on the region of phase space explored More details TEMPthe system temperature=300 ARG the biases that must be taken into account when reweighting=metad.rbias,restr_rmsd.bias
HISTOGRAMAccumulate the average probability density along a few CVs from a trajectory. This action is a shortcut and it has hidden defaults. More details ...
ARGthe quantities that are being used to construct the histogram=rho,c
GRID_MIN the lower bounds for the grid=0.,0
GRID_MAX the upper bounds for the grid=3.0,160
GRID_BINthe number of bins for the grid=300,160
KERNEL the kernel function you are using=DISCRETE
LOGWEIGHTSthe logarithm of the quantity to use as the weights when calculating averages=weights
LABELa label for the action so that its output can be referenced in the input to other actions=histoThe HISTOGRAM action with label histo calculates the following quantities: Quantity | Type | Description |
histo | grid | the estimate of the histogram as a function of the argument that was obtained |
UPDATE_FROMOnly update this action from this time=200000
UPDATE_UNTILOnly update this action until this time=1000000
... HISTOGRAM
HISTOGRAMAccumulate the average probability density along a few CVs from a trajectory. This action is a shortcut and uses the defaults shown here. More details ...
ARGthe quantities that are being used to construct the histogram=rho,c
GRID_MIN the lower bounds for the grid=0.,0
GRID_MAX the upper bounds for the grid=3.0,160
GRID_BINthe number of bins for the grid=300,160
KERNEL the kernel function you are using=DISCRETE
LOGWEIGHTSthe logarithm of the quantity to use as the weights when calculating averages=weights
LABELa label for the action so that its output can be referenced in the input to other actions=histo
UPDATE_FROMOnly update this action from this time=200000
UPDATE_UNTILOnly update this action until this time=1000000
NORMALIZATION This controls how the data is normalized it can be set equal to true, false or ndata=ndata STRIDE the frequency with which to store data for averaging=1 CLEAR the frequency with whihc to clear the data that is being averaged=0
... HISTOGRAM
# HISTOGRAM ...
histo_weightThe CONSTANT action with label histo_weight calculates the following quantities: Quantity | Type | Description |
histo_weight | scalar | the constant value that was read from the plumed input |
: ONESCreate a constant vector with all elements equal to one More details SIZEthe number of ones that you would like to create=1
histo_kdeThe KDE action with label histo_kde calculates the following quantities: Quantity | Type | Description |
histo_kde | grid | a function on a grid that was obtained by doing a Kernel Density Estimation using the input arguments |
: KDECreate a histogram from the input scalar/vector/matrix using KDE More details ARGthe label for the value that should be used to construct the histogram=rho,c GRID_MIN the lower bounds for the grid=0.,0 GRID_MAX the upper bounds for the grid=3.0,160 GRID_BINthe number of bins for the grid=300,160 KERNEL the kernel function you are using=DISCRETE
histo_kdepThe CUSTOM action with label histo_kdep calculates the following quantities: Quantity | Type | Description |
histo_kdep | grid | the grid obtained by doing an element-wise application of an arbitrary function to the input grid |
: CUSTOMCalculate a combination of variables using a custom expression. More details ARGthe values input to this function=histo_kde,histo_weight FUNCthe function you wish to evaluate=x*y PERIODICif the output of your function is periodic then you should specify the periodicity of the function=NO
histo_uThe ACCUMULATE action with label histo_u calculates the following quantities: Quantity | Type | Description |
histo_u | grid | a sum calculated from the time series of the input quantity |
: ACCUMULATESum the elements of this value over the course of the trajectory More details ARGthe label of the argument that is being added to on each timestep=histo_kdep STRIDE the frequency with which the data should be collected and added to the quantity being averaged=1 CLEAR the frequency with which to clear all the accumulated data=0 UPDATE_FROMOnly update this action from this time=200000 UPDATE_UNTILOnly update this action until this time=1e+06
histo_nsumThe ACCUMULATE action with label histo_nsum calculates the following quantities: Quantity | Type | Description |
histo_nsum | scalar | a sum calculated from the time series of the input quantity |
: ACCUMULATESum the elements of this value over the course of the trajectory More details ARGthe label of the argument that is being added to on each timestep=histo_weight STRIDE the frequency with which the data should be collected and added to the quantity being averaged=1 CLEAR the frequency with which to clear all the accumulated data=0 UPDATE_FROMOnly update this action from this time=200000 UPDATE_UNTILOnly update this action until this time=1e+06
histoThe CUSTOM action with label histo calculates the following quantities: Quantity | Type | Description |
histo | grid | the grid obtained by doing an element-wise application of an arbitrary function to the input grid |
: CUSTOMCalculate a combination of variables using a custom expression. More details ARGthe values input to this function=histo_u,histo_nsum FUNCthe function you wish to evaluate=x/y PERIODICif the output of your function is periodic then you should specify the periodicity of the function=NO
# --- End of included input --- # --- Click here to hide input ---
ffThe CONVERT_TO_FES action with label ff calculates the following quantities: Quantity | Type | Description |
ff | grid | the free energy surface |
: CONVERT_TO_FESConvert a histogram to a free energy surface. This action is a shortcut. More details GRIDthe histogram that you would like to convert into a free energy surface (old syntax)=histo TEMPthe temperature at which you are operating=300
# ff: CONVERT_TO_FES GRID=histo TEMP=300
ffThe CUSTOM action with label ff calculates the following quantities: Quantity | Type | Description |
ff | grid | the grid obtained by doing an element-wise application of an arbitrary function to the input grid |
: CUSTOMCalculate a combination of variables using a custom expression. More details ARGthe values input to this function=histo FUNCthe function you wish to evaluate=-2.49434*log(x) PERIODICif the output of your function is periodic then you should specify the periodicity of the function=NO
# --- End of included input ---
and finally printed
Click on the labels of the actions for more information on what each action computes
# --- Click here to reveal hidden parts of input file ----
rho: READRead quantities from a colvar file. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=rho IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
The READ action with label rho calculates the following quantities: Quantity | Description |
rho..#!custom | the names of the output components for this action depend on the actions input file see the example inputs below for details |
c: READRead quantities from a colvar file. More details FILEthe name of the file from which to read these quantities=results/coord_rho.dat VALUESthe values to read from the file=c IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
The READ action with label c calculates the following quantities: Quantity | Description |
c..#!custom | the names of the output components for this action depend on the actions input file see the example inputs below for details |
metad: READRead quantities from a colvar file. More details FILEthe name of the file from which to read these quantities=results/metad_data.dat VALUESthe values to read from the file=metad.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
The READ action with label metad calculates the following quantities: Quantity | Description |
metad..#!custom | the names of the output components for this action depend on the actions input file see the example inputs below for details |
restr_rmsd: READRead quantities from a colvar file. More details FILEthe name of the file from which to read these quantities=results/rmsd_restraint.dat VALUESthe values to read from the file=restr_rmsd.* IGNORE_FORCES use this flag if the forces added by any bias can be safely ignored IGNORE_TIME ignore the time in the colvar file
The READ action with label restr_rmsd calculates the following quantities: Quantity | Description |
restr_rmsd..#!custom | the names of the output components for this action depend on the actions input file see the example inputs below for details |
weights: REWEIGHT_BIASCalculate weights for ensemble averages that negate the effect the bias has on the region of phase space explored More details TEMPthe system temperature=300 ARG the biases that must be taken into account when reweighting=metad.rbias,restr_rmsd.bias
The REWEIGHT_BIAS action with label weights calculates the following quantities: Quantity | Description |
weights.value | the weight to use for this frame to negate the effect the bias |
HISTOGRAMAccumulate the average probability density along a few CVs from a trajectory. More details ...
ARGthe quantities that are being used to construct the histogram=rho,c
GRID_MIN the lower bounds for the grid=0.,0
GRID_MAX the upper bounds for the grid=3.0,160
GRID_BINthe number of bins for the grid=300,160
KERNEL the kernel function you are using=DISCRETE
LOGWEIGHTSthe logarithm of the quantity to use as the weights when calculating averages=weights
LABELa label for the action so that its output can be referenced in the input to other actions=histo
UPDATE_FROMOnly update this action from this time=200000
UPDATE_UNTILOnly update this action until this time=1000000
... HISTOGRAM
The HISTOGRAM action with label histo calculates the following quantities: Quantity | Description |
histo.value | the estimate of the histogram as a function of the argument that was obtained |
ff: CONVERT_TO_FESConvert a histogram to a free energy surface. More details GRIDthe histogram that you would like to convert into a free energy surface (old syntax)=histo TEMPthe temperature at which you are operating=300
# --- Click here to hide input ---
The CONVERT_TO_FES action with label ff calculates the following quantities: Quantity | Description |
ff.value | the free energy surface |
DUMPGRIDOutput the function on the grid to a file with the PLUMED grid format. More details GRIDthe grid you would like to print (can also use ARG for specifying what is being printed)=ff FILE the file on which to write the grid=reweighted_fes.dat
From this data we can plot the 2D free energy landscape reweighted on $\rho$ and $c$:
Free energy surface projected along the new CVs.
∆G calculation
In the GitHub folder you can find a simple python script to get the free energy difference between two basins, deltaG.py
. You have to input the path of the reweighted FES, the minima and the maxima in x and y for both the basins and it returns the free energy difference. For my run, we defined the two minima and obtained this result:
$> python3 deltaG.py reweighted_fes.dat 0.45 0.55 105 115 2. 2.8 0 0.5
The free energy difference between basin A and basin B is -3.53 kcal/mol
We now have $\Delta G_{\text{MetaD}}$, the last step is the calculation of the entropic correction.
Entropic correction calculation
We have to compute the volume of the protein included in the sphere. To do so, we can again use VMD. After loading the structure, we open the Tk console and select all the atom that are within 2.8 nm from the center of mass we computed in the previous step of the tutorial:
set sel [atomselect top "sqrt((x-35.28876876831055)^2 + (y-34.06196594238281)^2 + (z-32.041622161865234)^2) < 28.0"]
having set up this selection, we can write an output PDB file.
$sel writepdb atoms_in_sphere.pdb
Having this file, we can use gmx sasa
to have an estimate of the volume of these atoms:
gmx sasa -f atoms_in_sphere.pdb -s atoms_in_sphere.pdb -tv volume.xvg
obtaining a volume of 27.294 nm$^3$.
Putting this value and $\rho_{\text{s}}=2.8$ nm in the formula we get the entropic correction
\[\begin{align*}
RT \log\left( \frac{V^{0}}{\frac{4}{3}\pi \rho_{\text{s}}^3 -V_{\text{host}}}\right)
&= -2.18 \text{ kcal/mol}
\end{align*}\]
And we have a final binding free energy value $\Delta G^{0}=-(3.53+2.18)$ kcal/mol $= -5.71$ kcal/mol, which is close to the experimental value of $-5.2$ kcal/mol obtained by Morton et al. in this work.