Bookmark and Share

Notice: On March 31, it was announced that Statalist is moving from an email list to a forum. The old list will shut down on April 23, and its replacement, is already up and running.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: "Hours" in Stata

From   C Engelbrecht <>
Subject   st: "Hours" in Stata
Date   Wed, 30 Jun 2010 16:34:19 -0400

Hi everyone,

I can't seem to find an answer to this in the Stata manual (version
11) so hopefully someone can help me with it. I have two time
variables in a dataset (%tc format), and I want to find out the
difference in them measured in hours. For example

04nov2009 17:01:54


05nov2009 16:26:33

The hh() function only extracts the "hour" portion. It helps, but not
easy to use in this case (when more than one day is involved). I tried
subtracting them directly, but I'm not sure what's the "unit" for %tc

*   For searches and help try:

© Copyright 1996–2015 StataCorp LP   |   Terms of use   |   Privacy   |   Contact us   |   Site index