empty_ref¶
- xarray_einstats.empty_ref(*args, dims, dtype=None)[source]¶
Create an empty DataArray from reference object(s).
Creates an empty DataArray from reference DataArrays or Datasets and a list with the desired dimensions.
- Parameters:
- *argsiterable of
xarray.DataArray
orxarray.Dataset
Reference objects from which the lengths and coordinate values (if any) of the given dims will be taken.
- dims
list
ofhashable
List of dimensions of the output DataArray. Passed as is to the {class}`~xarray.DataArray` constructor.
- dtype
dtype
, optional The dtype of the output array. If it is not provided it will be inferred from the reference DataArrays in args with
numpy.result_type
.
- *argsiterable of
- Returns: