Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

NumPy unique Example Get unique values from a 1D Numpy array

# welcome to softhunt.net
import numpy as np

duplicates = np.array([2,3,3,4,5,5,1,5,4,6,7,5,1,5,3,5,1,3])

# GET UNIQUE VALUES
ans = np.unique(duplicates)
print(ans)
Source by softhunt.net #
 
PREVIOUS NEXT
Tagged: #NumPy #unique #Example #Get #unique #values #Numpy #array
ADD COMMENT
Topic
Name
9+1 =