relative deviation

From: Lena Frey <frey_l_at_nyahnyahspammersnyahnyah>
Date: Thu Jun 27 2013 - 13:54:47 MDT
I would like to calculate the relative deviation of  two zonal mean meridional stream functions (zonal_mpsi).
My configuration is:
Delta = ((psi2-psi)/psi)*100
Delta!0 = "lev"
Delta!1 = "lat"
Delta&lat = lat
Delta&lev = lev_p
Delta&lev@units = "hPa"
   if(any(ismissing(Delta))) then
        print("Your data contains some missing values. Beware.")
   end if
     if (any(isnan_ieee(Delta))) then
        value = -1.e34
        replace_ieeenan (Delta, value, 0)
        Delta@_FillValue = value
    end if
I get the error message "fatal:divide: Division by 0, Can't continue" and "fatal:Div: operator failed, can't continue".
Another problem are the values of my deviation. I use the function printMinMax(Delta,0) and get wrong values. 
What is the best way to calculate relative deviations?
Has anyone an idea? Thanks.

ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
Received on Thu Jun 27 13:54:57 2013

This archive was generated by hypermail 2.1.8 : Fri Jul 05 2013 - 13:06:49 MDT