|
Getting Started with IDL: Plotting Irregularly Gridded Data |
|
The TRIANGULATE procedure constructs a Delaunay triangulation of a planar set of points. After a triangulation has been found for a set of irregularly-gridded data points, the TRIGRID function can be used to interpolate surface values to a regular grid.
WINDOW
TRIANGULATE,X,Y,TR
The variable TR now contains a three-element by 54-element longword array (you may see this by typing "Help, TR" at the IDL Command Line).
| Note This is not always a 54-element array, it may vary based on the number of points. |
PLOT,X,Y,PSYM=1,TITLE='Triangulation' FOR i=0,N_ELEMENTS(TR)/3 - 1 DO BEGIN & T= $ [TR[*, i],TR[0, i]] & PLOTS,X[T],Y[T] & ENDFOR
![]() |
WDELETE
IDL Online Help (March 06, 2007)