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

Home » Public Forums » archive » loop for where command
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: loop for where command [message #43185 is a reply to message #43038] Thu, 17 March 2005 11:45 Go to previous message
Benjamin Hornberger is currently offline  Benjamin Hornberger
Messages: 258
Registered: March 2004
Senior Member
anu wrote:
> hi
>
> thanks for the tip .. it works !!
> but i am not able to extract the data further into separate arrays
>

Well, say a is your original array and you could extract all indices of
ones (1's) into the variable "ones_indices" then you can extract them
into a separate array by

ones_array = a[ones_indices]

Of course, if you know that you have "count" ones in your array, this is
equivalent to

ones_array = replicate(1, count)
[Message index]
 
Read Message
Read Message
Previous Topic: Re: loop for where command
Next Topic: Re: changing array dimensions

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

Current Time: Fri Oct 10 20:02:02 PDT 2025

Total time taken to generate the page: 1.43923 seconds