[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]
Re: st: Setting today's date in a do-file
Patrick Woodburn <firstname.lastname@example.org> has a do-file that
contains the line
global today "d(21nov2006)"
but he has to remember to change the line each time he runs the file. "Is
there any way to automatically obtain today's date?", he asks.
Change the line to read
global today "d(`c(current_date)')"
`c(current_date)' is today's date in string form, i.e., "21 Nov 2006".
-cret list- will list the other commonly requested things Stata has
available for you. See -help creturn- for more details.
* For searches and help try: