squeeze(dim=None, drop=False, axis=None)¶
Return a new object with squeezed data.
Hashableor iterable of
Hashable, 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.
bool, optional) – If
drop=True, drop squeezed coordinates instead of making them scalar.
squeezed – This object, but with with all or a subset of the dimensions of length 1 removed.
- Return type
same type as caller