xarray_scatter_where
- PlasmaCalcs.plotting.scatter.xarray_scatter_where(arr, condition=None, *, x, y, t=None, **kw_scatter)
use XarrayScatter to plt.scatter() markers wherever arr==True.
Roughly equivalent: arr[y].where(arr).pc.scatter(x=x, t=t, **kw_scatter)arr: xarray.DataArrayarray of bools, or array to be provided to condition if condition is callable.condition: None, array of bools, or callableNone –> use condition =arr, andarrmust be array of bools.array –> ignore arr entirely.conditionmust be array of bools.callable –> use condition = condition(arr), which must return array of bools.x: strcoordinate to use for x-axis values.y: strcoordinate to use for y-axis values.t: None or strcoordinate to use for “time” (iterate across movie frames).None –> probably can’t animate; might show all points in 1 frame.[TODO] optionally infer x, y, t automatically if not provided directly.additional kwargs go to XarrayScatterreturns XarrayScatter object.