Opened 10 years ago
Last modified 6 years ago
#2346 new enhancement
r.timestamp: support also YYYY-DOY
Reported by: | neteler | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | 7.6.2 |
Component: | LibGIS | Version: | svn-releasebranch70 |
Keywords: | r.timestamp, t.register, temporal, doy | Cc: | |
CPU: | Unspecified | Platform: | All |
Description
It would be of great help (esp. for time series) to add year/doy (Day Of Year) support to r.timestamp. From this t.register would benefit as well.
The "only" change needed seems to be an upgrade of G_scan_timestamp():
http://grass.osgeo.org/programming7/scan_8c_source.html#l00043
probably by adding a new function scan_doy() Day Of Year
Change History (11)
comment:1 by , 10 years ago
Keywords: | temporal doy added |
---|
comment:2 by , 10 years ago
This must be implemented in the C datetime library and in the temporal framework parser in datetime_math.py[1]. I hoped that the dateutils[2] already support this to have it out of the box, but unfortunately they don't.
Hence we should orient on the ISO 8601 standard for ordinal dates when implementing this (YYYY-DDD) but not YYYYDDD, since the temporal framework and the C datetime library also support relative time and can't decide if 1900031 is 31. Jan. 1900 or if it is the number of seconds, days, ... .
[1] http://grass.osgeo.org/programming7/datetime__math_8py_source.html#l00704 [2] https://labix.org/python-dateutil
comment:4 by , 9 years ago
Milestone: | 7.0.4 → 7.0.5 |
---|
comment:5 by , 8 years ago
Milestone: | 7.0.5 → 7.3.0 |
---|
comment:8 by , 6 years ago
Milestone: | 7.4.1 → 7.4.2 |
---|
comment:9 by , 6 years ago
Milestone: | 7.4.2 → 7.6.0 |
---|
If doing this, try to follow some consistent terminology/naming.
I've recently encountered different namings in GRASS: DOY, Day of Year, day of year, doy, daynum and day.