dqa.connectors.exporter.PlotExporter#
- class dqa.connectors.exporter.PlotExporter(y_name: str | List[str] | None = None, x_name: str | List[str] | None = None, factors: List[float | str] | None = None, fmt: str | List[str] | None = None, labels: str | List[str] | None = None, color_by: str | None = None, show_by: str | None = 'Machine', show_legend: bool = True, x_label: str | None = None, y_label: str | None = None, plot_type: str = 'plot', **kwargs)#
Exports data by plotting.
- Parameters:
y_name (str or list of str) – Name of the data rows to represent the y coordinates in the plot.
x_name (str or list of str, default=None) – Name of the data rows to represent the x coordinates. If None, then a default range will be used.
factors (list of str or float, default=None) – Factors to multiply the data with. If passed as floats, the values will be used directly. If passed as strings, the values will be taken from the corresponding data row.
fmt (str or list of str, default=None) – Format strings for the plotted lines.
labels (str or list of str, default=None) – The labels of the lines to be shown in the plot. Otherwise the labels are the names of the data rows.
color_by (str, default=None) – Determines on which level new colors are chosen in the cycle. Possible values are ‘Measurement’, ‘Dataset’, ‘Machine’ and None. For None, no color is specified.
show_by (str or None, default='Machine') – Determines on which level the plots are shown. For example if set to ‘Machine’, then the data for each machine is plotted and at the end shown once for the entire machine. If None, then the plot is not shown.
show_legend (bool, default=True) – Indicates if the legend should be shown in the plot.
plot_type (str, default='plot') – The type of plot to be generated (with the coresponding plt.* function). Possible values are ‘plot’ and ‘step’.
Methods
finish
()Can perform actions that are required to clean up after the task has finished, e.g. close network connections etc.
next_in_level
(level, name)Finishes the plot on one level, e.g. Dataset, Machine, Measurement.
export_data_row
export_dataset
export_dataset_dict
export_machine
export_measurement
finish_export
in_out_default
input_output_dataset
input_output_machine
input_output_mode
input_output_name
log
modify_data_row
modify_dataset
modify_dataset_dict
modify_machine
modify_measurement
set_logging_level
start_export
transfer_metadata