# 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('a23ffa56-d669-47a0-8e41-ce6691e1025f','faadb041-8efd-48ec-9bb9-9ca62f1b3a1e','0b20948d-a06f-40d7-a049-446a143a73b6','../lite/tree/../notebooks/index.html?path=10bf3245_402c_4e71_bb12_2d12760c4be2.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="0b20948d-a06f-40d7-a049-446a143a73b6" class="try_examples_outer_iframe  hidden"><div class="try_examples_button_container"><button class="try_examples_button" onclick="window.tryExamplesHideIframe('a23ffa56-d669-47a0-8e41-ce6691e1025f','0b20948d-a06f-40d7-a049-446a143a73b6')">Go Back</button><button class="try_examples_button" onclick="window.openInNewTab('a23ffa56-d669-47a0-8e41-ce6691e1025f','0b20948d-a06f-40d7-a049-446a143a73b6')">Open In Tab</button></div><div id="faadb041-8efd-48ec-9bb9-9ca62f1b3a1e" class="jupyterlite_sphinx_iframe_container"></div></div><script>document.addEventListener("DOMContentLoaded", function() {window.loadTryExamplesConfig("../try_examples.json");});</script>
