comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » cmset_op question (Craig)
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
cmset_op question (Craig) [message #38346] Wed, 03 March 2004 08:56
jbattat is currently offline  jbattat
Messages: 8
Registered: November 2003
Junior Member
Hello,

I've been using cmset_op with abandon and have really appreciated it.
Recently, I found behaviour that was unexpected to me.

Here's the example:

IDL> a = [1]
IDL> b = ['1']
IDL> print, cmset_op(a, 'and' a)
1
IDL> print, cmset_op(b, 'and' b)
1 1

cmset_op returns unique values in the case of an integer array but not
in the case of a string array.

Is this intended?
And if so, how can I return the unique elements of a string array
using cmset_op?

I know that I can use uniq() built into idl, but would prefer to use
cmset_op if possible.

Thanks in advance,
James
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Working with indices of WHERE
Next Topic: Re: Working with indices of WHERE

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Thu Oct 09 21:21:40 PDT 2025

Total time taken to generate the page: 0.00578 seconds