🍾 Xarray is now 10 years old! 🎉

xarray.DataArray.str.isupper

xarray.DataArray.str.isupper#

DataArray.str.isupper()[source]#

Check whether all characters in each string are uppercase.

Returns:

isupper (array of bool) – Array of boolean values with the same shape as the original array.

Examples

>>> da = xr.DataArray(["TEMPERATURE", "humidity", "PreCIpiTAtioN"], dims="x")
>>> da
<xarray.DataArray (x: 3)> Size: 156B
array(['TEMPERATURE', 'humidity', 'PreCIpiTAtioN'], dtype='<U13')
Dimensions without coordinates: x
>>> isupper = da.str.isupper()
>>> isupper
<xarray.DataArray (x: 3)> Size: 3B
array([ True, False, False])
Dimensions without coordinates: x