pyqmmm.md.restraint_plotter

Creates a series of KDE plots based on HYSCORE-guided simulations

Module Contents

Functions

config()

Parses the config file for the users parameters.

combine_inp()

Combines a CPPTRAJ output file with angles and another with distances.

get_xy_data(filename)

Takes a combined file and destructures it into arrays.

collect_xyz_data(filenames)

Retrieves the x and y data from the files.

compare_patch_limits(x_data, y_data, patch_params)

Checks all the data sets and decides what the x and y bounds should be.

get_plot_limits(x_data, y_data, plot_params)

graph_datasets(x_data, y_data, z_data, labels, ...)

restraint_plots()

pyqmmm.md.restraint_plotter.config()[source]

Parses the config file for the users parameters.

Returns:

  • labels (dictionary) – Contains labels section where the key is the name and the values is itself

  • plot_params (list) – A list of dictionaries where the index is the plot number and the values are the associated floats from the config file

pyqmmm.md.restraint_plotter.combine_inp()[source]

Combines a CPPTRAJ output file with angles and another with distances.

Returns:

  • combined (file) – Generates a file with the combined distances and angles for each plot.

  • file_array (list) – List of all the files that are generated.

pyqmmm.md.restraint_plotter.get_xy_data(filename)[source]

Takes a combined file and destructures it into arrays.

Parameters:

filename (str) – The name of the file.

Returns:

  • x (array) – The x-values, most likely a list of distances.

  • y (array) – The y-values, most likely a list of angles.

pyqmmm.md.restraint_plotter.collect_xyz_data(filenames)[source]

Retrieves the x and y data from the files.

Parameters:

filenames (list) – List of the combined file names that were generated.

Returns:

  • x_data (array) – A list of values in the x dimension

  • y_data (array) – A list of values in the y dimension

  • z_data (array) – A list of values in the z dimension

pyqmmm.md.restraint_plotter.compare_patch_limits(x_data, y_data, patch_params)[source]

Checks all the data sets and decides what the x and y bounds should be.

Parameters:
  • x_data (list) – A list of lists with the x data for each plot as a list within the list

  • y_data (list) – A list of lists with the y data for each plot as a list within the list

  • patch_params (list) – The dimensions of the patch as min and max for the height and width

Returns:

  • xlim (list) – The lowest and highest values on the x-axis

  • ylim (list) – The lowest and highest values on the y-axis

pyqmmm.md.restraint_plotter.get_plot_limits(x_data, y_data, plot_params)[source]
pyqmmm.md.restraint_plotter.graph_datasets(x_data, y_data, z_data, labels, plot_params, show_crosshairs)[source]
pyqmmm.md.restraint_plotter.restraint_plots()[source]