# xarray.CFTimeIndex.notna

#### CFTimeIndex.notna()[[source]](https://github.com/pydata/xarray/blob/main/xarray/../.pixi/envs/doc/lib/python3.15/site-packages/pandas/core/indexes/base.py#L2813-L2855)

Detect existing (non-missing) values.

Return a boolean same-sized object indicating if the values are not NA.
Non-missing values get mapped to `True`. Characters such as empty
strings `''` or `numpy.inf` are not considered NA values.
NA values, such as None or `numpy.NaN`, get mapped to `False`
values.

* **Returns:**
  `numpy.ndarray[bool]` – Boolean array to indicate which entries are not NA.

#### SEE ALSO
`Index.notnull`
: Alias of notna.

`Index.isna`
: Inverse of notna.

[`notna`](#xarray.CFTimeIndex.notna)
: Top-level notna.

### Examples

<div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesShowIframe('a4032cb1-678d-4786-95b9-93ad08fbf6fd','33392bbd-171b-4b36-b731-64eb5b58811d','394d8583-f81d-4031-bb61-3b73cf185b2d','../lite/tree/../notebooks/index.html?path=bbd2c681_87ea_48b2_b8a5_b40031527154.ipynb','None')">Try it in your browser!</button></div>

Show which entries in an Index are not NA. The result is an
array.

```pycon
>>> idx = pd.Index([5.2, 6.0, np.nan])
>>> idx
Index([5.2, 6.0, nan], dtype='float64')
>>> idx.notna()
array([ True,  True, False])
```

Empty strings are not considered NA values. None is considered a NA
value.

```pycon
>>> idx = pd.Index(["black", "", "red", None])
>>> idx
Index(['black', '', 'red', nan], dtype='str')
>>> idx.notna()
array([ True,  True,  True, False])
```

<div id="394d8583-f81d-4031-bb61-3b73cf185b2d" class="try_examples_outer_iframe  hidden"><div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesHideIframe('a4032cb1-678d-4786-95b9-93ad08fbf6fd','394d8583-f81d-4031-bb61-3b73cf185b2d')">Go Back</button><button class="try_examples_button" onclick="window.openInNewTab('a4032cb1-678d-4786-95b9-93ad08fbf6fd','394d8583-f81d-4031-bb61-3b73cf185b2d')">Open In Tab</button></div><div id="33392bbd-171b-4b36-b731-64eb5b58811d" class="jupyterlite_sphinx_iframe_container"></div></div><script>document.addEventListener("DOMContentLoaded", function() {window.loadTryExamplesConfig("../try_examples.json");});</script>
