|
From: Fadzil M. <fad...@gm...> - 2014-02-23 17:28:30
|
Hi,
I just started using Python for the last few weeks, and previously been
using GrADS for around 4 years.
I have trouble looking for a simplest way to calculate area average, let
say I need to calculate a SST over a region of 20S-10N and 130E-170E.
I know how to get one point values of SST vs Time, as in:
********************************************************************
...
...
f = nc.Dataset('d:/data/sst.mon.mean.nc', 'r')
sstv = f.variables['sst']
timev = f.variables['time']
sst = sstv[:, 35, 100]
plt.plot(timev,sst)
plt.show()
...
...
***********************************************************************
but I couldn't figure out how to get an area average value (...and didn't
get the right reference in the internet either)
Something missing, probably because I don't understand enough about slicing
or something else.
Can anyone give me a hint ?
Thanks.
Fadzil.
|