suboptimumg.sweep.sweep_results_1var#

class suboptimumg.sweep.sweep_results_1var.SweepResults1Var(sweep_data, dependencies={})[source]#

Bases: object

Parameters:
  • sweep_data (SweepData1D)

  • dependencies (Dict[str, Callable])

dydx_at_x(x, y_var=SweepDatatype.TOTAL_PTS)[source]#
Return type:

float

Parameters:
grid_plot(show_event_times=False, rows=2, cols=3, *, title=None, x_label=None, y_label=None, **kwargs)[source]#

Creates a dynamic grid plot for 1D event results.

Parameters:
  • show_event_times (bool, optional) – Whether to show event times on the plot instead of points (default is False)

  • rows (int, optional) – Number of rows in the grid (default is 2)

  • cols (int, optional) – Number of columns in the grid (default is 3)

  • title (str, optional) – Overall grid title. If empty, a default is generated.

  • x_label (str, optional) – Common X-axis label. Defaults to var_name.

  • y_label (str, optional) – Common Y-axis label.

  • **kwargs (dict) – Additional arguments passed to plot_grid_2D (fit_curve, theme, font_config, layout_config, smoothing_config)

Returns:

Plotly figure object

Return type:

go.Figure

plot(y_var=SweepDatatype.TOTAL_PTS, *, title=None, subtitle=None, x_label=None, y_label=None, data_label=None, **kwargs)[source]#

Plot a single sweep datatype.

Parameters:
  • y_var (SweepDatatype, optional) – SweepDatatype to plot on y-axis (default is SweepDatatype.TOTAL_PTS)

  • title (str, optional) – Plot title (defaults to “{var_name} Sweep”)

  • subtitle (str, optional) – Plot subtitle (auto-generated from dependencies if None)

  • x_label (str, optional) – X-axis label (defaults to var_name)

  • y_label (str, optional) – Y-axis label (defaults to TITLE_MAPPING)

  • data_label (str, optional) – Label for the data series in legend

  • **kwargs (dict) – Additional arguments passed to plot2D (h_line, v_line, fit_curve, show_points, theme, font_config, layout_config, smoothing_config)

Returns:

Plotly figure object

Return type:

go.Figure

y_at_x(x, y_var=SweepDatatype.TOTAL_PTS)[source]#
Return type:

float | ndarray[tuple[Any, ...], dtype[float64]]

Parameters:
  • x (float | ndarray[tuple[Any, ...], dtype[float64]])

  • y_var (SweepDatatype)