Astrobrowse Time Formats (Proposed)
GLU specification would be: Date($sys,$fmt)
- $sys : "UTC", "TAI", or "other".
- $fmt : one or more of the variables defined in the first column of the table below.
GLU $fmt | description | Ab submit fmt | example |
YYYY | 4-digit year | $YYYY$ | 1999 |
YYYYffff | 4-digit year with fractional year | $YYYYffff$ | 1999.0877 |
YY | 2-digit year | $YY$ | 99 |
DDD | 3-digit day of year | $DDD$ | 032 |
DDDffffff | 3-digit day of year with 6-digit fractional day | $DDDffffff$ | 032.218142 |
MM | 2-digit month | $MM$ | 02 |
DD | 2-digit day of month | $DD$ | 01 |
DDfff | 2-digit day of month with 3-digit fractional day | $DD$ | 01.218 |
hh | 2-digit hour of day | $hr$ | 05 |
mm | 2-digit minute of hour | $mn$ | 14 |
ss | 2-digit seconds of minute | $ss$ | 07 |
ssff | seconds of minute with fractional secs | $ssff$ | 07.45 |
hhffff | hours with decimal fraction of hours | $hhffff$ | 05.1242 |
month | name of month in lowercase | $month$ | february |
Month | name of month with first letter uppercase | $Month$ | February
|
mon | abbrev name of month | $mon$ | feb |
JD | Julian Date | $jd$ | 2451210.71814178 |
TJD | Truncated Julian Date | $tjd$ | 11210.2181417824 |
MJD | Modified Julian Date | $mjd$ | 51210.2181417824 |
SHF | SHF: short history file time key | $shf$ | 602313260 |
XTE | XTE mission day with fractional day | $shf$ | 1857.21818287037 |
Most resources will want a combination of the above variables. Here is how to get GLU to put together frequently-needed combinations: eg Date(UTC,%YY.%DDD) for the first one.
GLU combination fmt | example |
%YY.%DDD | 99.032 |
%YYYY-%MM-%DD | 1999-02-01 |
%YYYY%DDD | 1999032 |
%YYYY%MM%DD (1) | 19990201 |
%YY%MM%DD | 990201 |
%YYYY/%MM/%DD | 1999/02/01 |
%mon %DD, %YYYY | feb 01, 1999 |
%mon/%DD/%YY | feb/01/99 |
%YY %mon %DD | 99 feb 01 |
%DD-%mon-%YY (2) | 01-feb-99 |
%MM/%DD/%YY | 02/01/99 |
%DD/%MM/%YY (3) | 01/02/99 |
%YYYY%DDD%hh | 199903205 |
%hh:%mm:%ss | 05:14:07 |
%hh%mm%ss | 051407 |
%hh:%mm | 0514 |
%YYYY-%MM-%DD %hh:%mm:%ss UTC (4) | 1999-02-01 05:14:07 UTC |
%YYYY/%MM/%DD %hh:%mm:%ss | 1999/02/01 05:14:07 |
%YY.%DDD %hh:%mm:%ss | 99.032 05:14:07 |
%YY %mon %DD %hh%mm%ss | 99 feb 01 051407 |
%MM/%DD/%YY %hh:%mm:%ss | 02/01/99 05:14:07 |
NOTES:
- (1) (http://archive.ast.cam.ac.uk/ingarch/ingarch.html (WDB))
- (2) (nrao_vla), also accepts DD-mon-YYYY
- (3) (CADC http://cadcwww.dao.nrc.ca/wdb/html/cadc_wdb.html)
- (4) W3Browse, almost ISO standard
- (5) ARNIE - eg EINSTEIN HRIIMAGE, ROSPUBLIC
- What about deltas?
- http://archive.eso.org/wdb/wdb/eso/eso_archive/form accepts dd/mm/yy, dd mmm yy, and ".." range, >value, MOKA2 uses YY, MM, DD (start and stop) in separate fields
- AAT accepts:yyyymmdd or yyyy/mm/dd or dd/mm/yy or dd mmm yyyy or mmm dd yy or yyyymmdd..yyyymmdd (for a range)
- ArnieV3 takes different dates/times: START_DATE=yy.ddd, END_DATE=yy.ddd, PUBLIC_DATE=shf (why?), START_TIME_MJD=mjd, END_TIME_MJD=mjd (ASCAPUB), times in SHF
- HST @ STScI accepts: Jul 15 1994
Jul 1994 15
15 Jul 1994
1994 Jul 15
1994 15 Jul
7/15/1994
7-15-1994
7.15.1994
(month is case-insensitive)
If the day is omitted, the first day of the month is assumed. This means that a specification like "July 1994" will look for observations done on July 1 1994
00:00:00, not for observations done during July 1994. Note also that when entering a date with the month in numerical format, the American ordeing is
used; i.e., the first number is the month.
If a time is omitted, then midnight (00:00:00) is assumed. Otherwise, you can specify a time in any of these formats:
14:30
14:30:20
14:30:20:999
14:30:20.9
4am
4 PM
04:30:20 AM
To search for observations before a given date, use <, and for observations after a given date, use >. For example,
> Jul 15 1994
< Jul 15 1994
You can use the .. operator to search on a range of dates:
Jul 1 1994 .. Aug 1 1995
This operator is inclusive on the first date and exclusive on the second.
Finally, you can search on a list of dates or date ranges. For example,
Jul 1 1994 .. Jul 3 1994, Dec 1 1995 .. Dec 6 1995
will search for observations done within either one of these date ranges.
- Allow users to input any format, or be more rigid?
- Allow <,>,.. ? (do something rational if not supported by a resource)
|