Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
From | Leny Mathew <lenymathewc@gmail.com> |
To | statalist@hsphsun2.harvard.edu |
Subject | Re: st: RE: converting SAS file to stata using stat transfer-date and time variables |
Date | Mon, 20 Dec 2010 15:40:29 -0500 |
Thanks Nick. It's weird considering that the conversion to excel works fine. I can convert it as a csv file and then get it into stata without any issue. On Fri, Dec 17, 2010 at 12:07 PM, Nick Cox <n.j.cox@durham.ac.uk> wrote: > I wouldn't assume much in this territory. Dates and times seem simple in principle but can be very awkward in practice. > > On this information, my only guess is that time (presumably time of day, up to 24hr) is being converted to fraction of a day. You need to look really closely at the data in SAS and in Stata. > > Nick > n.j.cox@durham.ac.uk > > Leny Mathew > > I'm trying to convert a SAS file (V 9.1) with date and time variables > (separate) into stata and I'm using stat transfer (version 8) for > this. During the conversion, the date variable comes across fine, but > all the time variable values are between 0 and 1. stat transfer reads > the SAS file without any problem, it looks fine in the viewer and it > converts into excel without any problem. I didn't have to format the > date variable within stata, so I'm assuming that I don't have to do > any formatting for the time variable either. Has anyone had this issue > before? > Any comments are much appreciated. I'm using stata 10.1 > > * > * For searches and help try: > * http://www.stata.com/help.cgi?search > * http://www.stata.com/support/statalist/faq > * http://www.ats.ucla.edu/stat/stata/ > * * For searches and help try: * http://www.stata.com/help.cgi?search * http://www.stata.com/support/statalist/faq * http://www.ats.ucla.edu/stat/stata/