PlasmaCalcs.addons.instability_tools.instability_theory_tools.xarray_growthplots

PlasmaCalcs.addons.instability_tools.instability_theory_tools.xarray_growthplots(array, *, klines=None, **kw)
like array.pc.subplots, but with default kwargs from kw_growthplot.
Also, plots array.it.growth.
(E.g. if array is complex, use array.imag instead.
and if array is actually a Dataset, use array[‘omega’].imag instead.)
Also, if array has kdims, and has only 1 nonk_dim, use defaults:
row = the nonkdim,
wrap = 6 if array.sizes[nonk dim] > 6. (actually itAccessor.GROWPLOT_WRAP; default 6.)
klines: None, bool, Dataset, dict, or tuple of (Dataset, dict)
whether to plot lines representing mean free paths, and debye lengths, on each subplot.
None –> True if input was a Dataset; False if it was a DataArray.
(cannot infer klims from DataArray of growth values.)
Dataset –> use to infer klims. Use only default kwargs for xarray_klines.
dict –> use as kwargs for xarray_klines. infer klims from array input (must be a Dataset).
tuple –> (Dataset, dict). use dataset to infer klims; use dict as xarray_klines kwargs.
Internally, uses different kwarg defaults than xarray_klines. Defaults here:
label = ‘{shortvar} ({fluid})’
add_legend = True for axs[0,0], False for all other plots.
log = infer from ylabel of top-left ax (if direction==’h’, else xlabel of bottom left.)