LeapGraph
code_loader.contract.visualizer_classes.LeapGraph
Used to visualize a 1D signal.
import numpy.typing as npt
from code_loader.contract.enums import LeapDataType
@dataclass
class LeapGraph:
data: npt.NDArray[np.float32]
type: LeapDataType = LeapDataType.Graph
x_label: Optional[str] = None
y_label: Optional[str] = None
x_range: Optional[Tuple[float,float]] = None
legend: Optional[List[str]] = NoneArgs
data
an np.ndarray float32 [N,1] array where N is the number of points in the graph.
x_label
(optional) - the x label for the graph
y_label
(optional) - the y label for the graph
x_range
(optional) - controlling the ticks on the x axis by supplying a minimum and maximum value
legend
(optional) - a legend for distinguishing between different lines plotted in the same graph
Examples
Basic Usage
Last updated
Was this helpful?

