CFLARE.plot_spectrum(n=None, real_only=False, show_eigengap=True, show_all_xticks=True, legend_loc=None, title=None, marker='.', figsize=(5, 5), dpi=100, save=None, **kwargs)

Plot the top eigenvalues in real or complex plane.

  • n (Optional[int]) – Number of eigenvalues to show. If None, show all that have been computed.

  • real_only (bool) – Whether to plot only the real part of the spectrum.

  • show_eigengap (bool) – When real_only = True, this determines whether to show the inferred eigengap as a dotted line.

  • show_all_xticks (bool) – When real_only = True, this determines whether to show the indices of all eigenvalues on the x-axis.

  • legend_loc (Optional[str]) – Location parameter for the legend.

  • title (Optional[str]) – Title of the figure.

  • marker (str) – Marker symbol used, valid options can be found in matplotlib.markers.

  • figsize (Optional[Tuple[float, float]]) – Size of the figure.

  • dpi (int) – Dots per inch.

  • save (Union[str, Path, None]) – Filename where to save the plot.

  • kwargs (Any) – Keyword arguments for matplotlib.pyplot.scatter().

Return type



Nothing, just plots the figure. Optionally saves it based on save.