Plotting API
skelarm.plotting
Provides utility functions for plotting robot arm states and trajectories.
draw_skeleton(ax, skeleton, color='blue', linewidth=2.0)
Draw the robot arm skeleton on a given Matplotlib Axes object.
:param ax: The Matplotlib Axes object to draw on. :param skeleton: The Skeleton object containing the robot arm's links. :param color: Color of the robot arm links. :param linewidth: Width of the lines representing the links.
Source code in src/skelarm/plotting.py
plot_trajectory(ax, trajectory_x, trajectory_y, color='red', linestyle='-', linewidth=1.0)
Plot a 2D trajectory on a given Matplotlib Axes object.
:param ax: The Matplotlib Axes object to draw on. :param trajectory_x: NumPy array of x-coordinates for the trajectory. :param trajectory_y: NumPy array of y-coordinates for the trajectory. :param color: Color of the trajectory line. :param linestyle: Style of the trajectory line (e.g., '-', '--', ':'). :param linewidth: Width of the trajectory line.