suboptimumg.plotting.plot_2d#
- suboptimumg.plotting.plot_2d.plot2D(x_list, y_list, title, x_axis, y_axis, h_line=None, v_line=None, fit_curve=False, show_points=False, subtitle=None, data_label=None, theme=None, font_config=None, layout_config=None, smoothing_config=None)[source]#
Generic 2D plotting utility.
- Parameters:
x_list (numpy.ndarray) – Numpy array of x coordinates
y_list (numpy.ndarray) – Numpy array of y coordinates
title (str) – Plot title
x_axis (str) – X-axis label
y_axis (str) – Y-axis label
h_line (ReferenceLineConfig, optional) – ReferenceLineConfig for horizontal reference line (None = no line)
v_line (ReferenceLineConfig, optional) – ReferenceLineConfig for vertical reference line (None = no line)
fit_curve (bool, optional) – Whether to fit a curve to the data points
show_points (bool, optional) – Whether to show individual data points
subtitle (str, optional) – Optional subtitle
data_label (str, optional) – Curve label used in legend
theme (str, optional) – Color theme name, see plotting.color_theme
font_config (FontConfig, optional) – FontConfig object for font settings
layout_config (LayoutConfig, optional) – LayoutConfig object for layout settings
smoothing_config (SmoothingConfig, optional) – SmoothingConfig object for smoothing settings
- Returns:
Plotly figure object
- Return type:
go.Figure