Many problems in statistical analysis include time-of-day variables, but Stata offers limited support for time-of-day calculations. Support is needed for dates with times, times alone, and durations or timings. This article presents two new programs as general utilities to convert back and forth between string and numeric representations.
CoxN. J.2003. Stata tip 2: Building with floors and ceilings. Stata Journal3: 446–447.
2.
CoxN. J.2005. Suggestions on Stata programming style. Stata Journal5: 560–567.
3.
GrahamR. L., KnuthD. E., and PatashnikO.1994. Concrete Mathematics: A Foundation for Computer Science.Reading, MA: Addison–Wesley.
4.
KnuthD. E.1997. The Art of Computer Programming. Volume I: Fundamental Algorithms.Reading, MA: Addison–Wesley.
5.
ReingoldE. M., and DershowitzN.2001. Calendrical Calculations: The Millennium Edition.Cambridge: Cambridge University Press. [See also http://www.calendarists.com for errata and extra material.]