MCPcopy
hub / github.com/pydata/xarray / len

Method len

xarray/core/accessor_str.py:283–291  ·  view source on GitHub ↗

Compute the length of each string in the array. Returns ------- lengths array : array of int

(self)

Source from the content-addressed store, hash-verified

281 return _apply_str_ufunc(func=func, obj=pat, dtype=np.object_)
282
283 def len(self) -> T_DataArray:
284 """
285 Compute the length of each string in the array.
286
287 Returns
288 -------
289 lengths array : array of int
290 """
291 return self._apply(func=len, dtype=int)
292
293 def __getitem__(
294 self,

Callers 3

test_daskFunction · 0.80
test_empty_str_methodsFunction · 0.80
test_lenFunction · 0.80

Calls 1

_applyMethod · 0.95

Tested by 3

test_daskFunction · 0.64
test_empty_str_methodsFunction · 0.64
test_lenFunction · 0.64