Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 17 additions & 4 deletions control/ctrlplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -195,12 +195,8 @@ def set_plot_title(self, title, frame='axes'):
----------
title : str
Title text.
fig : Figure, optional
Matplotlib figure. Defaults to current figure.
frame : str, optional
Coordinate frame for centering: 'axes' (default) or 'figure'.
**kwargs : `matplotlib.pyplot.suptitle` keywords, optional
Additional keywords (passed to matplotlib).

"""
_update_plot_title(
Expand Down Expand Up @@ -540,6 +536,23 @@ def _make_legend_labels(labels, ignore_common=False):

def _update_plot_title(
title, fig=None, frame='axes', use_existing=True, **kwargs):
"""Set or extend the centered title of a figure.

Parameters
----------
title : str
Title text.
fig : Figure, optional
Matplotlib figure. Defaults to the current figure.
frame : str, optional
Coordinate frame for centering: 'axes' (default) or 'figure'.
use_existing : bool, optional
If True (default), extend the figure's existing title instead of
replacing it.
**kwargs : `matplotlib.pyplot.suptitle` keywords, optional
Additional keywords (passed to matplotlib).

"""
if title is False or title is None:
return
if fig is None:
Expand Down
2 changes: 1 addition & 1 deletion control/phaseplot.py
Original file line number Diff line number Diff line change
Expand Up @@ -1257,7 +1257,7 @@ def phase_plot(odefun, X=None, Y=None, scale=1, X0=None, T=None,

Parameters
----------
func : callable(x, t, ...)
odefun : callable(x, t, ...)
Computes the time derivative of y (compatible with odeint). The
function should be the same for as used for `scipy.integrate`.
Namely, it should be a function of the form dx/dt = F(t, x) that
Expand Down
Loading