;+ ; NAME: ; uniqv ; PURPOSE: (one line) ; return the unique values (not indices) for an array ; DESCRIPTION: ; ; CATEGORY: ; Util ; CALLING SEQUENCE: ; v = uniqv(array, nosort=nosort) ; INPUTS: ; array - the array ; KEYWORD INPUT PARAMETERS: ; nosort - true if the array is already in monotonic order ; OUTPUTS: ; the unique values of the array ; MODIFICATION HISTORY: ; 2008 Dec 27 Leslie Young SwRI ;- function uniqv, array, nosort=nosort if keyword_set(nosort) then begin return, array[uniq(array)] endif else begin return, array[uniq(array, sort(array))] endelse end