Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: converting string to date
From
Nilay Kumar <[email protected]>
To
[email protected]
Subject
st: converting string to date
Date
Fri, 29 Nov 2013 12:15:29 -0500
I have a dataset where weeks are listed as strings ie. 2004-01-04 - 2004-01-10. How can I convert this entire string to dates?
I tried gen date1= date(var, “20YMD”) but that does not seem to work for this
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/