Code:
* Example generated by -dataex-. For more info, type help dataex clear input str7 date_string long countyfips "3/15/20" 1001 "3/16/20" 1001 "3/17/20" 1001 "3/18/20" 1001 "3/19/20" 1001 "3/20/20" 1001 "3/21/20" 1001 "3/22/20" 1001 "3/23/20" 1001 "3/24/20" 1001 "3/25/20" 1001 "3/26/20" 1001 "3/27/20" 1001 "3/28/20" 1001 "3/29/20" 1001 "3/30/20" 1001 "3/31/20" 1001 "4/1/20" 1001 "4/10/20" 1001 "4/11/20" 1001 "4/12/20" 1001 "4/13/20" 1001 "4/14/20" 1001 "4/15/20" 1001 "4/16/20" 1001 "4/17/20" 1001 "4/18/20" 1001 "4/19/20" 1001 "4/2/20" 1001 "4/20/20" 1001 "4/21/20" 1001 "4/22/20" 1001 "4/23/20" 1001 "4/24/20" 1001 "4/25/20" 1001 "4/26/20" 1001 "4/27/20" 1001 "4/28/20" 1001 "4/29/20" 1001 "4/3/20" 1001 "4/30/20" 1001 "4/4/20" 1001 "4/5/20" 1001 "4/6/20" 1001 "4/7/20" 1001 "4/8/20" 1001 "4/9/20" 1001 "5/1/20" 1001 "5/2/20" 1001 "5/3/20" 1001 end
I have tried encode and sorted using the newly generated long format. The issue still persists.
I have tried using date function: gen date = date(date_string, "MDY"). It generates missing values even though there are no missing values in date_string.
Thanks.
Comment