[ncl-talk] Probability calculation
Sunmin Park
mireiyue at gmail.com
Tue May 26 14:58:32 MDT 2015
Dear NCL users
I am trying to get rtest and ttest values from cross correlation lag 0. ESCORC was used to calculate cross correlation and I did rtest first then ttest using the equation from here https://www.ncl.ucar.edu/Document/Functions/Built-in/rtest.shtml. However, the ttest value are not correct when I printout Min Max values (min=0 max=805.891).
How I can fix this?
Here is script I used to calculate.
massvsext1 = escorc(CMF3,EXT) ; calc cross correlations
massvsext = mask(massvsext1,landmask,0)
printVarSummary(massvsext)
Nr = dimsizes(CMF3&time)
prob = rtest(massvsext,Nr,0)
probt = prob1*sqrt((Nr-2)/(1-prob1^2))
probt!0 = "lat"
probt!1 = "lon"
lat = fspan(-90,90,180)
lon = fspan(-180,180,360)
probt&lat = lat
probt&lon = lon
lat at longname = "latitude"
probt&lat at units = "degrees_north"
lon at longname ="longitude"
probt&lon at units = "degrees_east"
printVarSummary(probt)
printMinMax(probt,0)
Thank you for helps and comments.
Sun-
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20150526/6a22c4c5/attachment.html
More information about the ncl-talk
mailing list