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

Home » Public Forums » archive » make mape
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: make mape [message #94727 is a reply to message #94726] Fri, 08 September 2017 02:56 Go to previous messageGo to previous message
Markus Schmassmann is currently offline  Markus Schmassmann
Messages: 129
Registered: April 2016
Senior Member
On 09/07/2017 06:56 PM, AGW wrote:
> On Tuesday, September 5, 2017 at 2:05:03 PM UTC+2, AGW wrote:
>> Hi,
>>
>> I have 10000 values of h at specific 10000 values of x and y, every
>> values stored in idlsave file, I want to combine all values of h
>> at specific x,y in new array take this form
>>
>> hh=[x,y,h]
>>
>> where
>>
>> IDL> help,h
>> h FLOAT = Array[1, 1, 56]
>
> Sorry for this confusion, I have map 500 x 1000 pixels, I want to
> calculate the velocity of some pixels, I calculate it correctly, I
> want to make map of velocity, but the problem is I did not calculate
> all pixels so I want to put the new values of velocity in origin
> position (x & y). How can I do it


; Creating example data:
x_all=randomu(seed,10000)
y_all=randomu(seed,10000)
x=[0:1:(1./499)]
y=[0:1:(1./999)]
values_all=sin(!dpi*2*x_all)*cos(!dpi*2*y_all)

; Data for 10000 points calculated:
IDL> help, x_all, y_all, value_all
X_ALL FLOAT = Array[10000]
y_ALL FLOAT = Array[10000]
VALUE_ALL FLOAT = Array[10000]

; and the coordinates of your desired map is given by
IDL> help, x, y
X FLOAT = Array[500]
Y FLOAT = Array[1000]

; then you can create your map by
yourMap = GRIDDATA( x_all, y_all, values_all , /grid, xout=x, yout=y)

; exact for comparison
exact=rebin( sin(!dpi*2*x) ,[500,1000])* $
rebin(transpose(cos(!dpi*2*y)),[500,1000])

; show
im=image([yourMap,exact,yourMap-exact])

; I hope this is what you want, good luck, Markus
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: EP Flux
Next Topic: Error plotting polyline entities from a shapefile

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

Current Time: Wed Oct 08 11:44:41 PDT 2025

Total time taken to generate the page: 0.00448 seconds