``graphVisual`` =============================================== .. py:module:: optimeed.visualize.graphs.graphVisual Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: optimeed.visualize.graphs.graphVisual.GraphVisual .. py:class:: GraphVisual(theWidgetGraphVisual) Provide an interface to a graph. A graph contains traces. .. py:method:: set_fontTicks(fontSize, fontname=None) Set font of the ticks :param fontSize: Size of the font :param fontname: Name of the font .. py:method:: set_numberTicks(number, axis) Set the number of ticks to be displayed :param number: Number of ticks for the axis :param axis: Axis (string, "bottom", "left", "right", "top") :return: .. py:method:: set_fontLabel(fontSize, color='#000', fontname=None) Set font of the axis labels :param fontSize: font size :param color: color in hexadecimal (str) :param fontname: name of the font .. py:method:: get_legend() -> optimeed.visualize.graphs.pyqtgraphRedefine.myLegend Get the legend .. py:method:: get_axis(axis) -> optimeed.visualize.graphs.pyqtgraphRedefine.myAxis Get the axis :param axis: Axis (string, "bottom", "left", "right", "top") :return: axis object .. py:method:: set_fontLegend(font_size, font_color, fontname=None) .. py:method:: set_label_pos(orientation, x_offset=0, y_offset=0) .. py:method:: set_color_palette(palette) .. py:method:: apply_palette() .. py:method:: hide_axes() .. py:method:: add_feature(theFeature) To add any pyqtgraph item to the graph .. py:method:: add_text(theStr, pos_x, pos_y, color=None, font=None) Convenient function to create and add a TextItem (see pyqtgraph doc) to the current graph :param theStr: text as string :param pos_x: x_coordinate as float :param pos_y: y_coordinate as float :param color: color of the text (tuple or hex) :param font: QFont for the text .. py:method:: remove_feature(theFeature) To remove any pyqtgraph item from the graph .. py:method:: add_data(idGraph, theData) .. py:method:: set_graph_properties(theTrace) This function is automatically called on creation of the graph .. py:method:: set_lims(xlim, ylim) Set limits of the graphs, xlim or ylim = [val_low, val_high]. Or None. .. py:method:: add_trace(idTrace, theTrace) Add a :class:`~optimeed.visualize.gui.widgets.graphsVisualWidget.TraceVisual.TraceVisual` to the graph, with index idTrace .. py:method:: set_legend() Set default legend options (color and font) .. py:method:: set_title(titleName, **kwargs) Set title of the graph :param titleName: title to set .. py:method:: get_trace(idTrace) -> optimeed.visualize.graphs.traceVisual.TraceVisual Return the :class:`~optimeed.visualize.gui.widgets.graphsVisualWidget.TraceVisual.TraceVisual` correspondong to the index idTrace .. py:method:: get_all_traces() Return a dictionary {idtrace: :class:`~optimeed.visualize.gui.widgets.graphsVisualWidget.TraceVisual.TraceVisual`}. .. py:method:: delete_trace(idTrace) Delete the trace of index idTrace .. py:method:: delete() Delete the graph .. py:method:: linkXToGraph(graph) Link the axis of the current graph to an other :class:`GraphVisual` .. py:method:: update() Update the traces contained in the graph .. py:method:: fast_update() Same as :meth:`~GraphVisual.update` but faster. This is NOT thread safe (cannot be called a second time before finishing operation) .. py:method:: axis_equal() .. py:method:: log_mode(x=False, y=False) .. py:method:: grid_off() Turn off grid