Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

However, latitude is rounded down to the second decimal place when OBS_RAWTABLE(jpraw_refcoord, jtotal) is calculated. As a results, the indexes are sometimes not in ascending order precisely and the sorting doesn't work well. The following table shows the example. ZOBSLAT should be at the latitude between ALAT(jlatN) and ALAT(jlatS) but it is not there (south side of ALAT(jlatS)).

StationID
OBSLAT
ZOBSLAT
OBSLON
ZOBSLONAltitudeALAT(jlatN)ALAT(jlatS)
3033756.32107.6233056.5521456.32728

I found there are about 200 snow depth observations and 400 2m temperature observations affected by the bug (at 0 UTC on 3 Dec 2020). In order to modify it, it seems to be better to be sorted in ascending order by latitude directly.

Code Block
firstline221
titlessa/sub/fg2obs.F90
linenumberstrue
!**   Used to compute averages (always in the same order)

call KEYSORT(irc, POBS, KLEN,key=kplat,transposed=.TRUE.)