silx.gui.plot.actions.fit#

silx.gui.plot.actions.fit module provides actions relative to fit.

The following QAction are available:

class FitAction(plot, parent=None)[source]#

QAction to open a FitWidget and set its data to the active curve if any, or to the first curve.

Parameters:
  • plotPlotWidget instance on which to operate

  • parent – See QAction

getXRange()[source]#

Returns the range on the X axis on which to perform the fit.

setXRangeUpdatedOnZoom(enabled)[source]#

Set whether or not to update the X range on zoom change.

Parameters:

enabled (bool)

isXRangeUpdatedOnZoom()[source]#

Returns the current mode of fitted data X range update.

Return type:

bool

getXData(copy=True)[source]#

Returns the X data used for the fit or None if undefined.

Parameters:

copy (bool) – True to get a copy of the data, False to get the internal data.

Return type:

Union[numpy.ndarray,None]

getYData(copy=True)[source]#

Returns the Y data used for the fit or None if undefined.

Parameters:

copy (bool) – True to get a copy of the data, False to get the internal data.

Return type:

Union[numpy.ndarray,None]

setFittedItemUpdatedFromActiveCurve(enabled)[source]#

Toggle fitted data synchronization with plot active curve.

Parameters:

enabled (bool)

isFittedItemUpdatedFromActiveCurve()[source]#

Returns True if fitted data is synchronized with plot.

Return type:

bool