# xarray.DataArray.str.isalnum

#### DataArray.str.isalnum()[[source]](https://github.com/pydata/xarray/blob/main/xarray/core/accessor_str.py#L876-L899)

Check whether all characters in each string are alphanumeric.

* **Returns:**
  **isalnum** ([array](https://numpy.org/doc/stable/glossary.html#term-array) of [`bool`](https://docs.python.org/3/builtins/functions.html#bool)) – Array of boolean values with the same shape as the original array.

### Examples

<div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesShowIframe('ef661522-f96f-4fb6-a832-dcd0a24ae2b1','196492d4-6e27-4e43-98a1-a91a1058d108','a606a673-c4b9-476c-a83a-ed68b0813f76','../lite/tree/../notebooks/index.html?path=ad72a458_e69d_499c_8ee9_d8075e6c4863.ipynb','None')">Try it in your browser!</button></div>
```pycon
>>> da = xr.DataArray(["H2O", "NaCl-"], dims="x")
>>> da
<xarray.DataArray (x: 2)> Size: 40B
array(['H2O', 'NaCl-'], dtype='<U5')
Dimensions without coordinates: x
>>> isalnum = da.str.isalnum()
>>> isalnum
<xarray.DataArray (x: 2)> Size: 2B
array([ True, False])
Dimensions without coordinates: x
```

<div id="a606a673-c4b9-476c-a83a-ed68b0813f76" class="try_examples_outer_iframe  hidden"><div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesHideIframe('ef661522-f96f-4fb6-a832-dcd0a24ae2b1','a606a673-c4b9-476c-a83a-ed68b0813f76')">Go Back</button><button class="try_examples_button" onclick="window.openInNewTab('ef661522-f96f-4fb6-a832-dcd0a24ae2b1','a606a673-c4b9-476c-a83a-ed68b0813f76')">Open In Tab</button></div><div id="196492d4-6e27-4e43-98a1-a91a1058d108" class="jupyterlite_sphinx_iframe_container"></div></div><script>document.addEventListener("DOMContentLoaded", function() {window.loadTryExamplesConfig("../try_examples.json");});</script>
