Re: UNIQ and structure arrays [message #36645] |
Thu, 09 October 2003 15:18 |
Craig Markwardt
Messages: 1869 Registered: November 1996
|
Senior Member |
|
|
Reimar Bauer <R.Bauer@fz-juelich.de> writes:
> Aleksandar Jelenak wrote:
[ ... ]
>> I am looking for methods/procedures of applying a UNIQ-like function to
>> a structure array, i.e. the entire structure record is compared for
>> uniqueness.
[ ... ]
> please can you provide a small example. At the moment I don't know why uniq
> should not work
Reimar, since structures can't be compared by using the EQ operator,
there is no way to use UNIQ on them.
To the original poster, it looks like you will have to make your own
version of UNIQ, which compares the individual fields of the
structure. It's not hard, since the logic of UNIQ is fairly simple.
Craig
--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@REMOVEcow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
|
|
|
|