Hello everyone, I'm brand new to learning STATA, so I apologize if I am omitting any pertinent information. I have looked through previous posts on this topic, but am having trouble understanding how to code it.
I am attempting to extract the year from the date listed.
The data is currently listed in this format: testdate is 2012-03-12 00:00:00
I would like to simply create a new column with the year from the testdate column.
I really appreciate the help.
Thanks.
Lori
Related Posts with Help Extracting Year from Date
Interaction: ## versus * - OR are differentDear Statalist: I have some queations METHOD ONE: I created the following interaction variables usi…
Performing factor analysis with panel dataHello everyone, I have panel data with six variables concerning governance quality for 59 countries…
Merging two datasets with a common variableHello all, I am using STATA 16 Please I want to merge two datasets, using the common variable medcod…
r(303) equation not found after using "test" command to see if coefficients = 0I am trying to test if the sum of coefficients is significantly different from 0, but for some reaso…
"( invalid name" r198 error while running a loop tempname sdgp_format postfile `sdgp_format' state gdp_pcap fyear using sdgp_format.dta forvalues j …
Subscribe to:
Post Comments (Atom)
0 Response to Help Extracting Year from Date
Post a Comment