Plotting irregularly spaced vectors on a map

From: John Kerfoot <johnkerfoot_at_nyahnyahspammersnyahnyah>
Date: Wed Feb 06 2013 - 08:10:56 MST

Good Morning,

I really like the graphics capabilities that NCL provides and I've been
writing some scripts analyze ocean surface current measurements measured
from high-frequency radar. Here's the problem I'm having:

The raw vector measurements are radial velocity vectors measured from a
single transmit/receive antenna located on shore. We receive a new radial
velocity file every hour which has a header, footer and the data. The data
is an array of irregularly spaced points at which the velocity measurements
are made. Here's a piece of the file:

%% Longitude Latitude U comp V comp
 55 %% (deg) (deg) (cm/s) (cm/s)
 56 -74.7654328 38.9953526 37.390 6.578
 57 -74.7650369 38.9929993 33.209 2.893
 58 -74.7649055 38.9906281 31.973 -0.012
 59 -74.7650393 38.9882570 30.224 -2.656
 60 -74.7654374 38.9859040 26.660 -4.711
 61 -74.7660967 38.9835870 16.681 -4.476
 62 -74.7670121 38.9813237 15.350 -5.593
 63 -74.7681768 38.9791312 19.292 -9.004
 64 -74.7695817 38.9770263 12.978 -7.498

....
EOF

I figured I could find all of the unique lat and lon values and use them to
reshape the U and V arrays into a grid (I've written functions to do all of
this) which would have mostly _FillValues, with interspersed vector
components. I could then use gsn_csm_vector to overlay the vectors on a
map created with gsn_csm_map.

The problem I'm running into is that, after reshaping the U and V arrays to
a grid and adding the appropriate lat/lon coordinate variables (which are
the unique values from the Latitude and Longitude arrays), I try to plot
the vectors using gsn_csm_vector and gsn_csm_map. I'm getting the
following errors/warnings:

warning:_NhlCreateSplineCoordApprox: Attempt to create spline approximation
for X axis failed: consider adjusting trXTensionF value
warning:_NhlCreateSplineCoordApprox: Attempt to create spline approximation
for Y axis failed: consider adjusting trYTensionF value
warning:IrTransInitialize: error creating spline approximation for
trXCoordPoints; defaulting to linear
warning:IrTransInitialize: error creating spline approximation for
trYCoordPoints; defaulting to linear

Is there any way to plot ungridded vectors onto a map in NCL? I found the
following thread:

http://www.ncl.ucar.edu/Support/talk_archives/2007/1104.html

but I don't think there was a published resolution.

Thanks,
John

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Wed Feb 6 08:11:06 2013

This archive was generated by hypermail 2.1.8 : Wed Feb 13 2013 - 09:25:58 MST