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

Home » Public Forums » archive » Re: Duplicates - a new twist
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: Duplicates - a new twist [message #39452 is a reply to message #39450] Tue, 18 May 2004 00:59 Go to previous message
Chris Lee is currently offline  Chris Lee
Messages: 101
Registered: August 2003
Senior Member
In article <d33d6a4b.0405171324.1272c4e0@posting.google.com>, "Martin
Doyle" <m.doyle@uea.ac.uk> wrote:


> Hello all,
> I have a problem which I've searched everywhere to try and solve...many
> posters on this newsgroup have had _similar_ problems but the
> resolutions didn't help me...anyway, here goes; I have a dataset which
> consists of 3 columns: longitude, latitude and a value for an emission
> ....
> What I need to do is to look through the dataset and sum the emissions
> when the coordinate is the same, resulting in a dataset with unique
> coordinates and a total emission for each grid point. Does anyone have
> ...
> Martin

Hi,

;data is fltarr(3,n)

;find possible collisions
d=sqrt(data[0,*]^2+data[1,*]^2)
threshold=1.0 ; numbers after the decimal point.
d=round(d*10^threshold)/10^threshold

;apply the single vector functions here, the result is a *possible* list
of collisions, since any point on a circle centred on the origin will
match, hopefully since your dealing with European data you won't collide
with anything in the Southern atlantic :)

There are probably better ways.

Chris.
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Re: IDL benchmarks - weird!!
Next Topic: ENUMLIST in IDLitComponent::RegisterProperty

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

Current Time: Sun Nov 30 10:38:46 PST 2025

Total time taken to generate the page: 0.95881 seconds