# xarray.CFTimeIndex.is_unique

#### CFTimeIndex.is_unique

Return if the index has unique values.

* **Returns:**
  [`bool`](https://docs.python.org/3/builtins/functions.html#bool)

#### SEE ALSO
`Index.has_duplicates`
: Inverse method that checks if it has duplicate values.

### Examples

<div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesShowIframe('0e7293f7-6f95-48b5-97a3-d026fb432460','a8ef2a57-ef23-4db4-9610-a2a76ef7932b','c0df43c0-6664-4036-bb61-db4b48e689ea','../lite/tree/../notebooks/index.html?path=1a750d3d_c4ea_4e43_a3e5_7764a41ff24f.ipynb','None')">Try it in your browser!</button></div>
```pycon
>>> idx = pd.Index([1, 5, 7, 7])
>>> idx.is_unique
False
```

```pycon
>>> idx = pd.Index([1, 5, 7])
>>> idx.is_unique
True
```

```pycon
>>> idx = pd.Index(["Watermelon", "Orange", "Apple", "Watermelon"]).astype(
...     "category"
... )
>>> idx.is_unique
False
```

```pycon
>>> idx = pd.Index(["Orange", "Apple", "Watermelon"]).astype("category")
>>> idx.is_unique
True
```

<div id="c0df43c0-6664-4036-bb61-db4b48e689ea" class="try_examples_outer_iframe  hidden"><div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesHideIframe('0e7293f7-6f95-48b5-97a3-d026fb432460','c0df43c0-6664-4036-bb61-db4b48e689ea')">Go Back</button><button class="try_examples_button" onclick="window.openInNewTab('0e7293f7-6f95-48b5-97a3-d026fb432460','c0df43c0-6664-4036-bb61-db4b48e689ea')">Open In Tab</button></div><div id="a8ef2a57-ef23-4db4-9610-a2a76ef7932b" class="jupyterlite_sphinx_iframe_container"></div></div><script>document.addEventListener("DOMContentLoaded", function() {window.loadTryExamplesConfig("../try_examples.json");});</script>
