Return a new DataArray object with squeezed data.
dim : None or str or tuple of str, optional
Selects a subset of the length one dimensions. If a dimension is selected with length greater than one, an error is raised. If None, all length one dimensions are squeezed.
squeezed : DataArray
This array, but with with all or a subset of the dimensions of length 1 removed.
Although this operation returns a view of this array’s data, it is not lazy – the data will be fully loaded.