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

Module grace

source code

Module for interfacing with Grace (also known as Xmgrace, Xmgr, and ace).

Functions [hide private]
list of str or None, list of int or None, list of int or None, list of str or None
axis_setup(data_type=None, norm=True)
Determine the axis information for relax data store specific data.
source code
str
determine_seq_type(spin_id=None)
Determine the spin sequence data type.
source code
list of list of str
get_data_types()
Get all of the data types to plot for the current data pipe.
source code
 
view(file=None, dir=None, grace_exe='xmgrace')
Execute Grace.
source code
 
write(x_data_type='res_num', y_data_type=None, spin_id=None, plot_data='value', file=None, dir=None, force=False, norm=True)
Writing data to a file.
source code
Variables [hide private]
  status = Status()
  __package__ = 'pipe_control'

Imports: system, warn, RelaxError, RelaxNoSequenceError, RelaxNoSimError, get_file_path, open_write_file, test_binary, write_xy_data, write_xy_header, RelaxWarning, pipe_control, count_molecules, count_residues, count_spins, exists_mol_res_spin_data, pipes, add_result_file, assemble_data, specific_analyses, Status


Function Details [hide private]

axis_setup(data_type=None, norm=True)

source code 

Determine the axis information for relax data store specific data.

Parameters:
  • data_type (list of str) - The axis data category (in the [X, Y] list format).
  • norm (bool) - The normalisation flag which if set to True will cause all graphs to be normalised to a starting value of 1.
Returns: list of str or None, list of int or None, list of int or None, list of str or None
The axis information. This includes the sequence type, the list of lower bounds, the list of upper bounds, and the axis labels.

determine_seq_type(spin_id=None)

source code 

Determine the spin sequence data type.

The purpose is to identify systems whereby only spins or only residues exist.

Parameters:
  • spin_id (str) - The spin identification string.
Returns: str
The spin sequence data type. This can be one of 'spin', 'res,' or 'mixed'.

get_data_types()

source code 

Get all of the data types to plot for the current data pipe.

Returns: list of list of str
A list of lists of all the allowable data type descriptions and their values.

view(file=None, dir=None, grace_exe='xmgrace')

source code 

Execute Grace.

Parameters:
  • file (str) - The name of the file to open in Grace.
  • dir (str) - The optional directory containing the file.
  • grace_exe (str) - The name of the Grace executable file. This should be located within the system path.

write(x_data_type='res_num', y_data_type=None, spin_id=None, plot_data='value', file=None, dir=None, force=False, norm=True)

source code 

Writing data to a file.

Parameters:
  • x_data_type (str) - The category of the X-axis data.
  • y_data_type (str) - The category of the Y-axis data.
  • spin_id (str) - The spin identification string.
  • plot_data (str) - The type of the plotted data, one of 'value', 'error', or 'sim'.
  • file (str) - The name of the Grace file to create.
  • dir (str) - The optional directory to place the file into.
  • force (bool) - Boolean argument which if True causes the file to be overwritten if it already exists.
  • norm (bool) - The normalisation flag which if set to True will cause all graphs to be normalised to a starting value of 1.