Hi Sanjiv,
I am not an expert of NCL.
But if you read documents about these two functions, you can see that one consider "missing value" while another ignore it.
If there are missing value in your dataset, the difference come from this.
Perhaps this is not the right answer of your problem?
Regards
Louis
--- En date de : Mar 2.11.10, Sanjiv Kumar <sanjivconscious@gmail.com> a écrit :
De: Sanjiv Kumar <sanjivconscious@gmail.com>
Objet: [ncl-talk] difference between avg and dim_avg (BIG DIFFERENCE ????????)
À: "ncl-talk USERS" <ncl-talk@ucar.edu>
Date: Mardi 2 novembre 2010, 16h54
Hello,
I am using follwing functions to calculate average monthly value for the mississipi river basin.
I have a mask file for the mississippi river basin that i used to mask the data.
PrintVarSummary(pcp)
Variable: pcp
Type: float
Total Size: 41880240 bytes
10470060 values
Number of Dimensions: 3
Dimensions and sizes: [month | 12] x [lat | 621] x [lon | 1405]
Coordinates:
month: [0..11]
lon: [-125.0208..-66.47912]
Number Of Attributes: 5
units : mm/month
long_name : monthly_prism_pcp
_FillValue : -9999
time_op_ncl : Climatology: 25 years
(1) 58.87543
(2) 74.17915
(3) 79.49629
(4) 102.1536
(5) 105.3508
(6) 89.25518
(7) 77.08332
(8) 74.19021
(9) 71.37045
(11) 63.43136
Average: 77.14
Option2:
do i= 0, 11
print(avg(pcp(month|i, lat|:, lon|:)))
end do
(0) 40.91084
(0) 43.56288
(0) 61.70639
(0) 72.314
(0) 98.81877
(0) 95.28362
(0) 84.07236
(0) 72.15498
(0) 67.86727
(0) 61.63789
(0) 59.42875
-----La pièce jointe associée suit-----
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Tue Nov 2 11:18:44 2010
This archive was generated by hypermail 2.1.8 : Mon Nov 08 2010 - 08:08:50 MST