Actually, not well known because 99.9% of the examples
use gridded data, you can use gsn_csm_contour_map with
'random' (station) data.
See Example 1 at:
     http://www.ncl.ucar.edu/Applications/station.shtml
==============================================================
There is no need to put the original data into a netCDF file.
Assuming, -1 is a missing value and the 3 sample lines
you sent are named "hrapy.txt"
   data = asciiread("hrapy.txt",-1,"float")
   data@_FillValue = -1.0
   lat  = data(3::6)
   lon  = data(4::6)
   val  = data(5::6)
   delete(data)                            ; not necessary
  ;print(lat+"  "+lon+"  "+val)            ; print all values (too long)
   print(lat(:9)+"  "+lon(:9)+"  "+val(:9)); print 1st 10 values
   iGood = ind(.not.ismissing(val))        ; subscripts of good values
         :
         :
   res@sfXArray                    = lon(iGood)
   res@sfYArray                    = lat(iGood)
   map = gsn_csm_contour_map(wks,val(iGood),res)
================================================================
When the variable passed to ' gsn_csm_contour_map ' is one dimensional
then the sf{X/Y}Array resources must be set to the appropriate values.
A proprietary software function is used to efficiently perform the
plotting.
D
  02/08/2013 12:17 PM, James Scott - NOAA Affiliate wrote:
> Arthur,
>
> You can't use "gsn_csm_contour_map" map with station data.  It expects
> the data to be on a monotonically increasing grid.  You will have to
> interpolate your station data to a regular lat/lon grid before using
> "gsn_csm_contour_map". I recommend using the "natgrid" function to
> interpolate.
> http://www.ncl.ucar.edu/Document/Functions/Built-in/natgrid.shtml
>
> -Jamie
>
> On Fri, Feb 8, 2013 at 12:00 PM, <ncl-talk-request@ucar.edu
> <mailto:ncl-talk-request@ucar.edu>> wrote:
>
>     Hi,
>
>     I am trying to plot observed rainfall data from the NOAA's River
>     Forecast
>     Center's website (http://water.weather.gov/precip/about.php). The
>     original
>     data came on an HRAP grid/format. It had to be decoded from a netcdf
>     file
>     to ascii text file. The text file gives the observed value of
>     precip. for
>     each lat/lon point. How can I plot data that only has it's lat/lon
>     reference?
>
>     The data looks like this with value being the precip. variable:
>
>
>     "id", "hrapx", "hrapy", "lat", "long", "value"
>     0, 14, 10, 23.496319, -118.658440, -1.000000
>     0, 15, 10, 23.503891, -118.624420, -1.000000
>
>
>
>     I tried putting the data into a netcdf file, then using the
>     "gsn_csm_contour_map" function/tool to do it, but I got a segmentation
>     fault error. I was using NCL 5.1.0, and saw that this NCL version
>     can only
>     handle variables no larger than 2 GB. So, I downloaded NCL version
>     (6.1.1),
>     and I still get the same error (segmentation fault). The size of
>     each .nc
>     file for the CONUS is 20507540 bytes which is not 2 GB.
>
>     Do you have and insight as to how I could solve this issue? It does not
>     seem hard to do.
>
>     -Arthur Eiserloh
>
>
>
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk
>
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Fri Feb  8 12:54:54 2013
This archive was generated by hypermail 2.1.8 : Wed Feb 13 2013 - 09:25:58 MST