diff --git a/filterpy/stats/stats.py b/filterpy/stats/stats.py index 4da77d6..bab4d55 100644 --- a/filterpy/stats/stats.py +++ b/filterpy/stats/stats.py @@ -362,8 +362,10 @@ def plot_gaussian_pdf(mean=0., variance=1., if mean_line: plt.axvline(mean) - ax.set_xlabel(xlabel) - ax.set_ylabel(ylabel) + if xlabel is not None: + ax.set_xlabel(xlabel) + if ylabel is not None: + ax.set_ylabel(ylabel) return ax