[Numpy-discussion] unique rows of array

Maria Liukis liukis at usc.edu
Tue Aug 18 02:01:22 EDT 2009


Josef,

Many thanks for the example! It should become an official NumPy  
recipe :)

Thanks again,
Masha
--------------------
liukis at usc.edu



On Aug 17, 2009, at 10:03 PM, josef.pktd at gmail.com wrote:

> On Tue, Aug 18, 2009 at 12:59 AM, Maria Liukis<liukis at usc.edu> wrote:
>>
>> On Aug 17, 2009, at 9:51 PM, Charles R Harris wrote:
>>
>>
>> On Mon, Aug 17, 2009 at 10:30 PM, Maria Liukis <liukis at usc.edu>  
>> wrote:
>>>
>>> Hello everybody,
>>> While re-implementing some Matlab code in Python, I've run into a  
>>> problem
>>> of finding a NumPy function analogous to the Matlab's "unique(array,
>>> 'rows')" to get unique rows of an array. Searching the web, I've  
>>> found a
>>> similar discussion from couple of years ago with an example:
>>
>> Just to be clear, do you mean finding all rows that only occur  
>> once in the
>> array?
>>
>> Yes.
>
> I interpreted your question as removing duplicates. It keeps rows that
> occur more than once.
> That's what my example is intended to do.
>
> Josef
>
>>
>> <snip>
>>
>> Chuck
>>
>>
>> _______________________________________________
>> NumPy-Discussion mailing list
>> NumPy-Discussion at scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>>
>> _______________________________________________
>> NumPy-Discussion mailing list
>> NumPy-Discussion at scipy.org
>> http://mail.scipy.org/mailman/listinfo/numpy-discussion
>>
>>
> _______________________________________________
> NumPy-Discussion mailing list
> NumPy-Discussion at scipy.org
> http://mail.scipy.org/mailman/listinfo/numpy-discussion

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/numpy-discussion/attachments/20090817/098f9915/attachment.html>


More information about the NumPy-Discussion mailing list