Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

avhrr data extraction

28 views
Skip to first unread message

anil

unread,
Jun 3, 2012, 5:36:40 PM6/3/12
to
Hi,
I have downloaded some daily ,04km, night time sea surface temperature
data from avhrr. an example:
ftp://podaac-ftp.jpl.nasa.gov/allData/avhrr/L3/pathfinder_v5/daily/night/04km/2002/252/

I want to read these data and extract the values for a region (defined
latitudes and longitudes). To read the data , I use:

file=hdf_sd_start('2002252.s04d1pfv50-sst.hdf')
indexa=hdf_sd_nametoindex(file,'lon')
indexb=hdf_sd_nametoindex(file,'lat')
indexc=hdf_sd_nametoindex(file,'sst')
varida=hdf_sd_select(file,indexa)
varidb=hdf_sd_select(file,indexb)
varidc=hdf_sd_select(file,indexc)
hdf_sd_getdata,varida,loni
hdf_sd_getdata,varidb,lati
hdf_sd_getdata,varidc,ssti
hdf_sd_endaccess,varida
hdf_sd_endaccess,varidb
hdf_sd_endaccess,varidc
hdf_sd_end,file

;bsloni=loni(4715:5057)
;bslati=lati(1006:1142)
end
I want to extract the latitudes (1006 to 1142) and longitudes (4715 to
5057) and the corresponding sea surface temperatures (sst's) .At the
end I need to end up with something like:
40.75 36.74 sst1
40.75 36.88 sst2
40.82 37.12 sst3
............................... and so on. How can i do this? Defining
a bsloni and bslati gives me the latitudes and longitudes but how do i
get the corresponding sst's? With some kind of a where function? or a
few for loops?or some other way?

John Coxon

unread,
Jun 6, 2012, 11:08:31 AM6/6/12
to
Hi anil (and apologies for the top-post). comp.lang.idl is kind of dead,
now. comp.lang.idl-pvwave is probably a far better bet, if you want an
answer.
--
John Coxon
http://www.chickensinenvelopes.net/
0 new messages