Package pipe_control :: Module pymol_control
[hide private]
[frames] | no frames]

Module pymol_control

source code

Module for interfacing with PyMOL.

Classes [hide private]
  Pymol
The PyMOL execution object.
Functions [hide private]
 
cartoon()
Apply the PyMOL cartoon style and colour by secondary structure.
source code
 
command(command)
Function for sending PyMOL commands to the program pipe.
source code
 
cone_pdb(file=None)
Display the cone geometric object.
source code
list of str
create_macro(data_type=None, style='classic', colour_start=None, colour_end=None, colour_list=None)
Create an array of PyMOL commands.
source code
 
frame_order(ave_pos='ave_pos', rep='frame_order', sim='simulation.pdb.gz', dir=None)
Display the frame order results (geometric object, average position and Brownian simulation).
source code
 
frame_order_ave_pos(root=None, path=None)
Display the PDB structure for the frame order average domain position.
source code
 
frame_order_sim(file=None, path=None)
Display the PDB structure for the frame order Brownian simulation.
source code
 
frame_order_geometric(root=None, path=None)
Display the frame order geometric object.
source code
 
macro_apply(data_type=None, style='classic', colour_start_name=None, colour_start_rgb=None, colour_end_name=None, colour_end_rgb=None, colour_list=None)
Execute a PyMOL macro.
source code
 
macro_run(file=None, dir=None)
Execute the PyMOL macro from the given text file.
source code
 
macro_write(data_type=None, style='classic', colour_start_name=None, colour_start_rgb=None, colour_end_name=None, colour_end_rgb=None, colour_list=None, file=None, dir=None, force=False)
Create a PyMOL macro file.
source code
 
represent_cone_axis(id=None)
Set up the PyMOL cone axis representation.
source code
 
represent_cone_object(id=None)
Set up the PyMOL cone object representation.
source code
 
represent_pivots(id=None)
Set up the PyMOL pivot object representation.
source code
 
represent_titles(id=None)
Set up the PyMOL title object representation.
source code
 
represent_rotor_object(id=None)
Set up the PyMOL rotor object representation.
source code
 
tensor_pdb(file=None)
Display the diffusion tensor geometric structure.
source code
 
vector_dist(file=None)
Display the XH bond vector distribution.
source code
 
view()
Start PyMOL.
source code
Variables [hide private]
  status = Status()
  pymol_obj = Pymol('external')
Pymol data container instance.
  __package__ = 'pipe_control'

Imports: dep_check, pymol, F_OK, access, getcwd, pardir, sep, PIPE, Popen, mktemp, sleep, warn, RelaxError, RelaxNoPdbError, RelaxNoSequenceError, RelaxWarning, delete, file_root, get_file_path, open_read_file, open_write_file, test_binary, find_pdb_files, exists_mol_res_spin_data, check_pipe, add_result_file, return_api, Status


Function Details [hide private]

command(command)

source code 

Function for sending PyMOL commands to the program pipe.

Parameters:
  • command (str) - The command to send into the program.

cone_pdb(file=None)

source code 

Display the cone geometric object.

Parameters:
  • file (str) - The name of the file containing the cone geometric object.

create_macro(data_type=None, style='classic', colour_start=None, colour_end=None, colour_list=None)

source code 

Create an array of PyMOL commands.

Parameters:
  • data_type (str) - The data type to map to the structure.
  • style (str) - The style of the macro.
  • colour_start (str or RBG colour array (len 3 with vals from 0 to 1)) - The starting colour of the linear gradient.
  • colour_end (str or RBG colour array (len 3 with vals from 0 to 1)) - The ending colour of the linear gradient.
  • colour_list (str or None) - The colour list to search for the colour names. Can be either 'molmol' or 'x11'.
Returns: list of str
The list of PyMOL commands.

frame_order(ave_pos='ave_pos', rep='frame_order', sim='simulation.pdb.gz', dir=None)

source code 

Display the frame order results (geometric object, average position and Brownian simulation).

Parameters:
  • ave_pos (str or None) - The file root of the average molecule structure.
  • rep (str or None) - The file root of the PDB representation of the frame order dynamics to create.
  • sim (str or None) - The full Brownian diffusion file name.
  • dir (str or None) - The name of the directory where the files are located.

frame_order_ave_pos(root=None, path=None)

source code 

Display the PDB structure for the frame order average domain position.

Parameters:
  • root (str) - The file root of the PDB file containing the frame order average structure.

frame_order_sim(file=None, path=None)

source code 

Display the PDB structure for the frame order Brownian simulation.

Parameters:
  • root (str) - The full Brownian diffusion file name.

frame_order_geometric(root=None, path=None)

source code 

Display the frame order geometric object.

Parameters:
  • root (str) - The file root of the PDB file containing the frame order geometric object.

macro_apply(data_type=None, style='classic', colour_start_name=None, colour_start_rgb=None, colour_end_name=None, colour_end_rgb=None, colour_list=None)

source code 

Execute a PyMOL macro.

Parameters:
  • data_type (str) - The data type to map to the structure.
  • style (str) - The style of the macro.
  • colour_start_name (str) - The name of the starting colour of the linear gradient.
  • colour_start_rgb (RBG colour array (len 3 with vals from 0 to 1)) - The RGB array starting colour of the linear gradient.
  • colour_end_name (str) - The name of the ending colour of the linear gradient.
  • colour_end_rgb (RBG colour array (len 3 with vals from 0 to 1)) - The RGB array ending colour of the linear gradient.
  • colour_list (str or None) - The colour list to search for the colour names. Can be either 'molmol' or 'x11'.

macro_run(file=None, dir=None)

source code 

Execute the PyMOL macro from the given text file.

Parameters:
  • file (str) - The name of the macro file to execute.
  • dir (str) - The name of the directory where the macro file is located.

macro_write(data_type=None, style='classic', colour_start_name=None, colour_start_rgb=None, colour_end_name=None, colour_end_rgb=None, colour_list=None, file=None, dir=None, force=False)

source code 

Create a PyMOL macro file.

Parameters:
  • data_type (str) - The data type to map to the structure.
  • style (str) - The style of the macro.
  • colour_start_name (str) - The name of the starting colour of the linear gradient.
  • colour_start_rgb (RBG colour array (len 3 with vals from 0 to 1)) - The RGB array starting colour of the linear gradient.
  • colour_end_name (str) - The name of the ending colour of the linear gradient.
  • colour_end_rgb (RBG colour array (len 3 with vals from 0 to 1)) - The RGB array ending colour of the linear gradient.
  • colour_list (str or None) - The colour list to search for the colour names. Can be either 'molmol' or 'x11'.
  • file (str) - The name of the macro file to create.
  • dir (str) - The name of the directory to place the macro file into.
  • force (bool) - Flag which if set to True will cause any pre-existing file to be overwritten.

represent_cone_axis(id=None)

source code 

Set up the PyMOL cone axis representation.

Parameters:
  • id (str) - The PyMOL object ID.

represent_cone_object(id=None)

source code 

Set up the PyMOL cone object representation.

Parameters:
  • id (str) - The PyMOL object ID.

represent_pivots(id=None)

source code 

Set up the PyMOL pivot object representation.

Parameters:
  • id (str) - The PyMOL object ID.

represent_titles(id=None)

source code 

Set up the PyMOL title object representation.

Parameters:
  • id (str) - The PyMOL object ID.

represent_rotor_object(id=None)

source code 

Set up the PyMOL rotor object representation.

Parameters:
  • id (str) - The PyMOL object ID.

tensor_pdb(file=None)

source code 

Display the diffusion tensor geometric structure.

Parameters:
  • file (str) - The name of the file containing the diffusion tensor geometric object.

vector_dist(file=None)

source code 

Display the XH bond vector distribution.

Parameters:
  • file (str) - The vector distribution PDB file.