- Main Page
- Tutorials
- Functions
- Release Notes
- Examples

Functions
setunique
Complete List of ArrayFire Functions ArrayFire Functions by Category » Vector Algorithms » | Set operations

Find unique values from an input. More...

## Functions
AFAPI array | setUnique (const array &in, const bool is_sorted=false)
| C++ Interface for getting unique values. More...
AFAPI af_err | af_set_unique (af_array *out, const af_array in, const bool is_sorted)
| C Interface for getting unique values. More...
AFAPI array | setunique (const array &in, const bool is_sorted=false)
| C++ Interface for getting unique values. More...

## Detailed Description

Find unique values from an input.

## Function Documentation

AFAPI af_err af_set_unique | ( | af_array * | out,
|  | const af_array | in,
|  | const bool | is_sorted
| ) |  |

C Interface for getting unique values.

Parameters

  [out] | out | will contain the unique values from `in`
  [in] | in | is the input array
  [in] | is_sorted | if true, skips the sorting steps internally

Returns
  AF_SUCCESS if the execution completes properly

AFAPI array af::setunique | ( | const array & | in,
|  | const bool | is_sorted = `false`
| ) |  |

C++ Interface for getting unique values.

Parameters

  [in] | in | is the input array
  [in] | is_sorted | if true, skips the sorting steps internally

Returns
  the unique values from `in`

Deprecated:
  Use setUnique instead

AFAPI array af::setUnique | ( | const array & | in,
|  | const bool | is_sorted = `false`
| ) |  |

C++ Interface for getting unique values.

Parameters

  [in] | in | is the input array
  [in] | is_sorted | if true, skips the sorting steps internally

Returns
  the unique values from `in`