prsctrl.data.plot.plot_XY#
- plot_XY(data: PrsData, min_n_wavelengths: int = 50, save_fig: bool | str | Path = False, get_spectrum_kw: dict | None = None, fig: Figure | None = None, ax: Axes | None = None, title: bool | str = True, colorbar: bool | Literal['separate'] | Axes | None = 'separate', colorbar_kw: dict | None = None, subplots_kw: dict | None = None, blue_above: bool = True) tuple[Figure, Axes] | tuple[None, None][source]#
Plot dI-X/I against dI-Y/I.
X-Y plots can provide information on where a spectral component comes from, since components with different time constants will have different angles in the plot.
mqutilis required to plot the data points in the color of the respective wavelength.- Parameters:
data – Photoreflectance data object.
min_n_wavelengths – Minimum number of wavelengths the data must have.
save_fig – If
True, save in the data directory as<data dir name>_XY-plane.pdf. If a path is given, the plot is saved at the path.get_spectrum_kw – Keyword arguments for
get_spectrum_data(), for exampletransforms. :param fig: Optional figure. If given,axmust be given as well.ax – Optional axes. If given,
figmust be given as well.title – If
True, use the data name as plot title. If str, use the given title.colorbar – If
True, draw a colorbar next to the plot on the same axis. If"separate", draw it on an axis to the right (which will have the same size). If an axis is given, draw onto it. Set toNoneorFalsefor no colorbar.colorbar_kw – Additional arguments to pass to
fig.colorbar(), for example{"location": "top"}to put the colorbar on top of the plot.subplots_kw – Keyword arguments to pass to
plt.subplots()if no figure and axes are given.blue_above – If
True, plot the points in order from red to blue wavelengths, otherwise from blue to red.
- Returns:
(Figure, axes) or
(None, None)if the plot is not drawn.