Recipe: Fortran program as OPeNDAP client: Difference between revisions
Line 197: | Line 197: | ||
# <code>T_file</code>: Instead of reading a downloaded NetCDF-4 file, we read an OPeNDAP URL. | # <code>T_file</code>: Instead of reading a downloaded NetCDF-4 file, we read an OPeNDAP URL. | ||
# <code>start</code>: Via the OPeNDAP URL, we can now access all time levels. The hourly <code>inst</code> files are available starting at 2005/15/15 2200z. Our desired time, 2006/09/18 0900z is then the 11772<sup>th</sup> file. | # <code>start</code>: Via the OPeNDAP URL, we can now access all time levels. The hourly <code>inst</code> files are available starting at 2005/15/15 2200z. Our desired time, 2006/09/18 0900z is then the 11772<sup>th</sup> file. | ||
# <code>nf90_inq_varid</code>: | # <code>nf90_inq_varid</code>: While in the downloaded file, the temperature variable appears in the uppercase (T), on the OPeNDAP server, this variable is in lowercase (see http://opendap.nccs.nasa.gov:9090/dods/OSSE/GEOS-5.12/BETA9/0.5000_deg/inst/inst01hr_3d_T_Cv). This is reflected in the call to nf90_inq_varid. | ||
==== Compile and run ==== | ==== Compile and run ==== |