arviz.sel_utils.xarray_sel_iter#
- arviz.sel_utils.xarray_sel_iter(data, var_names=None, combined=False, skip_dims=None, reverse_selections=False)[source]#
Convert xarray data to an iterator over variable names and selections.
Iterates over each var_name and all of its coordinates, returning the variable names and selections that allow properly obtain the data from
data
as desired.- Parameters:
- data
xarray.Dataset
Posterior data in an xarray
- var_names
iterator
ofstrings
(optional) Should be a subset of data.data_vars. Defaults to all of them.
- combinedbool
Whether to combine chains or leave them separate
- skip_dims
set
dimensions to not iterate over
- reverse_selectionsbool
Whether to reverse selections before iterating.
- data
- Returns: