table_step package#
Submodules#
table_step.table module#
Non-graphical part of the Table step in SEAMM
- class table_step.table.Table(flowchart=None, extension=None)[source]#
Bases:
Node
- description_text(P=None)[source]#
Return a short description of this step.
Return a nicely formatted string describing what this step will do.
- Keyword Arguments:
P – a dictionary of parameter values, which may be variables or final values. If None, then the parameters values will be used as is.
- property git_revision#
The git version of this module.
- property version#
The semantic version of this module.
table_step.table_parameters module#
Control parameters for loops
- class table_step.table_parameters.TableParameters(defaults={}, data=None)[source]#
Bases:
Parameters
The control parameters for tables
- parameters = {'column': {'default': 'current', 'default_units': '', 'description': 'Column:', 'enumeration': ('c', 'u', 'r', 'r', 'e', 'n', 't'), 'format_string': '', 'help_text': 'The column to access', 'kind': 'string'}, 'columns': {'default': [], 'default_units': '', 'description': 'columns', 'enumeration': (), 'format_string': '', 'help_text': 'The column definitions.', 'kind': 'list'}, 'file type': {'default': 'from extension', 'default_units': '', 'description': 'File type:', 'enumeration': ('from extension', '.csv', '.json', '.xlsx', '.txt'), 'format_string': '', 'help_text': 'The type of file to read/write.', 'kind': 'string'}, 'filename': {'default': '', 'default_units': '', 'description': 'File name:', 'enumeration': (), 'format_string': '', 'help_text': 'The file name for the table, which may include a path.', 'kind': 'string'}, 'frequency': {'default': 1, 'default_units': '', 'description': 'Frequency:', 'enumeration': (), 'format_string': '', 'help_text': 'Number of calls before saving the table.', 'kind': 'integer'}, 'index column': {'default': '--none--', 'default_units': '', 'description': 'Index column:', 'enumeration': ('-', '-', 'n', 'o', 'n', 'e', '-', '-'), 'format_string': '', 'help_text': 'The column to index the table. Values must be unique.', 'kind': 'string'}, 'method': {'default': 'Create', 'default_units': '', 'description': '', 'enumeration': ('Create', 'Read', 'Save', 'Save as', 'Print', 'Print the current row of', 'Append a row to', 'Go to the next row of', 'Add columns to', 'Set element of', 'Get element of'), 'format_string': 's', 'help_text': 'What to do with the tables', 'kind': 'enumeration'}, 'row': {'default': 'current', 'default_units': '', 'description': 'Row:', 'enumeration': ('c', 'u', 'r', 'r', 'e', 'n', 't'), 'format_string': '', 'help_text': 'The row to access', 'kind': 'string'}, 'table name': {'default': 'table1', 'default_units': '', 'description': ' table ', 'enumeration': (), 'format_string': '', 'help_text': 'The name of the table.', 'kind': 'string'}, 'value': {'default': '', 'default_units': '', 'description': 'Value:', 'enumeration': (), 'format_string': '', 'help_text': 'The value to put into the table.', 'kind': 'string'}, 'variable name': {'default': '', 'default_units': '', 'description': 'Variable name:', 'enumeration': (), 'format_string': '', 'help_text': 'The name of the variable for storing the value from the table.', 'kind': 'string'}}#
table_step.table_step module#
Helper class needed for the stevedore integration.
This must provide a description() method that returns a dict containing a description of this node, and create_node() and create_tk_node() methods for creating the graphical and non-graphical nodes.
- class table_step.table_step.TableStep(flowchart=None, gui=None)[source]#
Bases:
object
- my_description = {'description': 'An interface for Pandas tables', 'group': 'Data', 'name': 'Table'}#
The description needs three fields:
- description:
A human-readable description of this step. It can be several lines long, and needs to be clear to non-expert users.
- group:
Which group in the menus to put this step. If the group does not exist it will be created. Common groups are ‘Building’, ‘Calculations’, ‘Control’ and ‘Data’.
- name:
The name of this step, to be displayed in the menus.
table_step.tk_table module#
The graphical part of a Table step
Module contents#
table_step A step for data tables in a SEAMM flowchart