Chartview#
Charting widget
- class mdaviz.chartview.CurveManager(*args: Any, **kwargs: Any)[source]#
- addCurve(row, *ds, **options)[source]#
Add a new curve to the manager if not already present on the graph.
- allCurvesRemoved#
alias of
bool
- curveAdded#
alias of
str
- curveRemoved#
alias of
str
- curveUpdated#
alias of
str
- findCurveID(file_path, row)[source]#
Find the curveID based on the file path and row number.
Parameters: - file_path (str): The path of the file associated with the curve. - row (int): The row number in the file tableview associated with the curve.
Returns: - str: The curveID if a matching curve is found; otherwise, None.
- generateCurveID(label, file_path)[source]#
Generates a unique curve label for a given label, considering the file path.
Parameters:
label (str): The original label for the curve: “file_name: PV_name (PV_unit)” or “file_name: PV_name” (if no PV_unit)
file_path (str): The file path associated with the curve.
Returns:
str: A unique curve label. If the exact label already exists for different file path, a numeric suffix is appended: “file_name: PV_name (PV_unit) (1)” or “file_name: PV_name (1)”
Note
This method allows each curve to be uniquely identified and selected, even if their base labels are identical, by considering their file paths.