Command Reference : Function Reference : Function Reference: U
  
 
@uniquevals
 
Vector or svector of unique values of object.
Syntax: @uniquevals(o)
o: series, matrix, vector, alpha
Return: vector, svector
Returns a vector or svector containing the list of unique values in the object specified by arg.
If arg is a series, vector or matrix, @uniquevals will return a vector object containing the unique elements of the series, vector or matrix.
If arg is an alpha series, @uniquevals will return an svector of the unique values in the alpha.
Examples
vector vals = @uniquevals(x)
returns a vector containing the unique values in x.
vector ivals = @sort(@uniquevals(x))
returns a vector of the unique values of X, sorted from low to high.
Cross-references
See also @dupselem, @dupsobs, and @dupsid.