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

Home » Public Forums » archive » WHERE functiom
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
WHERE functiom [message #50250] Fri, 22 September 2006 10:41
m.goullant@gmail.com is currently offline  m.goullant@gmail.com
Messages: 10
Registered: July 2006
Junior Member
Hi there, I have a simple question for many of you :). Where is an
example:

;point cloud (X,Y,Z)
x = data.x
y = data.y
z = data.z

;lets get only a point
i = 870
radio = 8

; getting only a part of the data
mySquare = WHERE(x LE x[i] + radio AND x GE x[i] - radio AND y LE y[i]
+ radio AND y GE y[i] - radio)

Distance = sqrt((x[mySquare] - x[i])^2 + (y[mySquare] - y[i])^2)

neighbours = WHERE(Distance LE radio)

This is the index returned by the first WHERE Funcion:
694 695 696 697 698 699
700 701 702 737 738 739
740 741 742 743 744 745
780
781 782 783 784 785
786 787 788 823 824 825
826 827 828 829 830 831
866 867 868
869 870 871 872 873
874 909 910 911 912 913
914 915 916 917 952 953
954 955 956
957 958 959 960 995
996 997 998 999 1000 1001
1002 1003 1038 1039 1040 1041
1042 1043 1044
1045 1046

and this is the index returned by the second WHERE function:
4 11 12 13 14 15
19 20 21 22 23 24
25 28 29 30 31 32
33
34 36 37 38 39
40 41 42 43 44 46
47 48 49 50 51 52
55 56 57
58 59 60 61 65
66 67 68 69 76


What can I do to preserve the same index?

Thank you,
Marie
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: @make vs command line for creating .sav files.
Next Topic: Re: WHERE functiom

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

Current Time: Wed Oct 08 17:35:01 PDT 2025

Total time taken to generate the page: 0.00539 seconds