Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • datetime conversion in Stata

    I have a string column (survey_completed_time) with dates in the following format,

    survey_completed_time
    Tue Apr 11 07:56:31 UTC 2017
    11/25/2015 6:34

    desired result,

    survey_completed_time
    11-Apr-2017
    25-Nov-2015

    I want to convert this to a datetime column with the format 11-Apr-2017. How can I achieve this in Stata?
    Last edited by Salah Uddin; 01 Aug 2024, 02:04.

  • #2
    Cross-posted at https://stackoverflow.com/questions/...rsion-in-stata

    Please note that you are asked to tell us about cross-posting.

    That's not one format, but two. How many other different formats do you have? The possible bad news is that you need to do a great deal of data cleaning to get anywhere.

    Comment


    • #3
      I figured out how to do it. It was quite messy.

      Comment


      • #4
        What is cross-posting?

        Comment


        • #5
          https://www.statalist.org/forums/help#crossposting

          https://dictionary.cambridge.org/dic.../cross-posting

          Comment

          Working...
          X