Hi!
I am very new to STATA. I have seen you answer different questions regarding date-variables. Hopefully you can help me with this:
I want to merge two variables:
v1=numeric yyyymmdd variable
v2=string yyyy-mm-dd variable
-->
newdatevariable=v1
replace newdatevariable=v2
if v2<v1 or missing(v1)
Kind regards,
Jenna Najar
0 Response to Create a new variable based on a date string variable yyyy-mm-dd and a numeric variable (yyyymmdd)
Post a Comment