point-correlation

From: Ibraheem Khan <khan18_at_nyahnyahspammersnyahnyah>
Date: Tue, 23 Jun 2009 22:29:18 -0500 (CDT)

Hi Everyone,

I am trying to plot a cross co-relation map of point value with gridded data. The following error is troubling.

fatal:Subscript out of range, error in subscript #2
fatal:An error occurred reading y
fatal:Execute: Error occurred at or near line 32 in file point_corr.ncl

and the script is as follows:

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"
load "$NCARG_ROOT/lib/ncarg/nclscripts/csm/shea_util.ncl"

begin
;**********************************************
; Reading Data and correlation function
;**********************************************
        f1 = addfile("6104_01.nc","r")
        f2 = addfile("tll_6104_01.nc","r")
        x1 = f1->a
        x2 = f2->a
        print(x1)
        print(x2)
        y = x1(lon|:,lat|:,time|:)
        c = escorc(y(:,:,0),x2)
        printVarSummary(c)

;**********************************************
; create plot
;*********************************************
  wks = gsn_open_wks ("ps","cor_prcp_01") ; open ps file

  gsn_define_colormap(wks,"radar")
  res = True
  res_at_cnFillOn = True
  res_at_cnLinesOn = False

  res_at_gsnSpreadColors = True
  res_at_lbAutoLabelStride = True

    res_at_cnLevelselectionMode = "ManualLevels" ; manually set cn levels
  res_at_cnMinLevelValF = -1. ; min level
  res_at_cnMaxLevelValF = 1. ; max level
  res_at_tiMainString = ":F25:Prcp Point Corr"

  res_at_gsnLeftString = " "
  res_at_tiMainFontHeightF = 0.03
  res_at_gsnAddCyclic = False
  plot = gsn_csm_contour_map_ce(wks,c,res)
end

It will be really great if anyone can help me out.
Thanks

-Ibraheem
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Jun 23 2009 - 21:29:18 MDT

This archive was generated by hypermail 2.2.0 : Thu Jun 25 2009 - 06:30:15 MDT