Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: Time/Date Functions

From   "Danielle H. Ferry" <>
Subject   st: Time/Date Functions
Date   Wed, 15 Mar 2006 16:43:34 -0500


I apologize in advance b/c I think the answer must be obvious - but I can't
seem to make this work and it is driving me nuts. 

I am trying to do the following:

tempvar time;
ge `time' = mdy(month, day, year);
ge junk = month(`time');

The var `time' works fine. But I get only missing values for junk. What am I
being thickheaded about? 

Danielle Ferry

National Bureau of Economic Research <>

*   For searches and help try:

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