A TauPlot -derived widget specialised in plotting trends (i.e., evolution of parameters).

TauTrend inherits all the features from TauPlot (zooming, exporting/importing, data inspection,...) and also provides some specific features (e.g. fixed-range X scale mode and Archiving support).
For an overview of the features from an user point of view, see the TauTrend User’s Interface Guide.
You can also see some code that exemplifies the use of TauTrend in the TauTrend coding examples
Note: if you pass a model that is a Tango SPECTRUM attribute (instead of a scalar), TauTrend will interpret it as a collection of scalar values and will plot a separate trend line for each.
applies the settings stored in a configdict to the current plot.
| Parameter: | configdict (dict) – |
|---|
See also
Shows a dialog to set the curves titles (it will change the current curves titles and the default curves titles)
| Parameter: | curveNamesList (string_sequence or string_iterator) – names of the curves to which the title will be changed (if None given , it will apply to all the TrendsSets and it will also be used as default for newly created ones) |
|---|---|
| Return type: | caselessDict <str, QString> or None |
| Returns: | The return value will be None if curveNamesList is None. Otherwise it will be a dictionary with key=curvename and value=newtitle. |
See also
setCurvesTitle(), setDefaultCurvesTitle()
Returns a pickable dictionary containing all relevant information about the current plot. For Tango attributes it stores the attribute name and the curve properties For raw data curves, it stores the data as well.
Hint: The following code allows you to serialize the configuration dictionary as a string (which you can store as a QSetting, or as a Tango Attribute):
import pickle
c = pickle.dumps(tauplot.createConfig()) #c is a string that can be stored
| Parameter: | names (sequence <str>) – a sequence of TrendSet names for which the configuration will be stored (all by default). |
|---|---|
| Return type: | dict |
| Returns: | configurations (which can be loaded with applyConfig) |
slot that is called whenever a curve emits a dataChanged signal
| Emits: | “dataChanged(const QString &)” |
|---|---|
| Parameter: | name (str) – curve name |
returns the maximum number of events that can be plotted in the trend
| Return type: | int |
|---|---|
| Returns: |
gets a trend set object by name.
Important: Note that the TrendSet object is not thread safe. Therefore, if you access it you must do it protected by the TauTrend.curves_lock reentrant lock.
| Parameter: | name (str) – the trend set name |
|---|---|
| Return type: | TauTrendSet |
| Returns: | the trend set object corresponding to name |
returns the names of all TrendSets attached to this TauTrend.
| Return type: | list <str> |
|---|---|
| Returns: | a copy of self.trendSets.keys() |
whether TauTrend is looking for data in the archiver when needed
| Return type: | bool |
|---|---|
| Returns: |
See also
type is the type of the property. It is either a type object or a string that is the name of a C++ type. freset is a function for resetting an attribute to its default value. designable sets the DESIGNABLE flag (the default is True for writable properties and False otherwise). scriptable sets the SCRIPTABLE flag. stored sets the STORED flag. user sets the USER flag. The other parameters are the same as those required by the standard Python property type. Properties defined using pyqtProperty behave as both Python and Qt properties.
sets the maximum number of events that can be plotted in the trends
| Parameter: | maxSize (int) – the maximum limit |
|---|
See also
TauTrendSet.setMaxDataBufferSize()
Pauses itself and other listeners (e.g. the trendsets) depending on it
See also
TauBaseComponent.setPaused()
Calls setTitleText(basetitle) for each Trend Set set in setNames
| Parameters: |
|---|
See: TauTrendsSet.setTitleText
enables/disables looking up in the archiver for data stored before the Trend was started
| Parameter: | enable (bool) – if True, archiving values will be used if available |
|---|
Defines the curves that need to be plotted. For a TauTrend, the models can refer to:
Note that passing an attribute for X values makes no sense in this case
Internally, every curve is grouped in a TauTrendSet. For each SPECTRUM attribute, a TrendSet is created, containing as many curves as the lenght of the spectrum For eacha SCALAR attribute, a TrendSet containing just one curve is created.
| Parameter: | names (sequence <str>) – a sequence of model names |
|---|
Note
Adding/removing a model will add/remove a whole set. No sub-set adding/removing is allowed. Still, each curve will be independent regarding its properties, and can be hidden/shown independently.
See also
type is the type of the property. It is either a type object or a string that is the name of a C++ type. freset is a function for resetting an attribute to its default value. designable sets the DESIGNABLE flag (the default is True for writable properties and False otherwise). scriptable sets the SCRIPTABLE flag. stored sets the STORED flag. user sets the USER flag. The other parameters are the same as those required by the standard Python property type. Properties defined using pyqtProperty behave as both Python and Qt properties.