[ncl-talk] Area averaging not being done in patter_cor function.

Shilpa Malviya shilpamalviya123 at gmail.com
Fri Apr 15 04:44:17 MDT 2016


Hi,

When we call pattern_cor function it then calls pattern_cor2 function to
compute the pattern correlation. I n case of centered correlation area
averaging is done , the code is as below

      sumWGT   = sum(WGT)
      xAvgArea = sum(x*WGT)/sumWGT      ; weighted area average
      yAvgArea = sum(y*WGT)/sumWGT

      xAnom    = x - xAvgArea           ; anomalies
      yAnom    = y - yAvgArea

if my weight is 1 it is simply the sum of the array not the area
average.This may lead to wrong results.

Is it because of this that when I perform centered averaging I get values
of the order of 0.6 and when uncentered then 0.9.

Regards,
Shilpa Malviya
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mailman.ucar.edu/pipermail/ncl-talk/attachments/20160415/28422211/attachment.html 


More information about the ncl-talk mailing list