Stata The Stata listserver
[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: convert from unix time to calendar time


From   "Karim R. Lakhani" <[email protected]>
To   [email protected]
Subject   st: convert from unix time to calendar time
Date   Thu, 26 Sep 2002 10:56:25 -0400

hello all,

I have some data (lots actually!) in which each record has a unix time
stamp (meaning epoch starting January 1, 1970 in seconds).  I would like
to convert this into a more useful calendar date and time.  Before I
write my own do file I was wondering if any one has come across this
problem before and found an easy way to solve it.  Solving it requires
converting seconds into the actual time, day, month year --> thus today,
September 26, 2002 at 10.30 am would convert to 1033036225 in unix time
(indicating how many seconds have elapsed since Jan 1, 1970).

Appreciate any help!

Thanks

Karim

*
*   For searches and help try:
*   http://www.stata.com/support/faqs/res/findit.html
*   http://www.stata.com/support/statalist/faq
*   http://www.ats.ucla.edu/stat/stata/



© Copyright 1996–2024 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   What's new   |   Site index