load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_code.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/gsn_csm.ncl" load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/contributed.ncl" begin fname = "tst.txt" n_col = numAsciiCol(fname) n_var = n_col n_pt = numAsciiRow(fname) dataf = asciiread(fname,(/n_pt,n_var/),"float") ;---read longitude lon = dataf (:,0) ;---read latitude lat = dataf (:,1) ;---read data for presence of convective cloud storm = dataf (:,2) ;---define the workstation (plot type and name) wks = gsn_open_wks("png","plot_field") ;--set resources wks = gsn_open_wks("x11","ce") res = True res@gsnMaximize = True res@mpDataBaseVersion = "MediumRes" ;-- map resolution res@mpMinLonF = min(lon) res@mpMaxLonF = max(lon) res@mpMinLatF = min(lat) res@mpMaxLatF = max(lat) res@sfXArray = lon res@sfYArray = lat res@cnFillOn = True ; Turn on contour fill. res@cnLinesOn = False ; Turn off contour lines ;-- create the contour map plot ; plot = gsn_csm_contour_map(wks,storm,res) ; create a default plot contour = gsn_csm_contour_map(wks,storm,res) end