Announcement

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

  • Generate time from date+time variable

    Hello All,

    I am a beginner with Stata, and I have a Time variable that looks like this:

    Time
    31dec1899 00:01:00
    31dec1899 00:02:00
    31dec1899 00:03:00
    31dec1899 00:04:00
    31dec1899 00:05:00
    31dec1899 00:06:00
    31dec1899 00:07:00
    31dec1899 00:08:00
    31dec1899 00:08:59
    31dec1899 00:10:00

    The storage type for this variable is double and display format %tc.

    1. I just need the time, that is 00:01:00. How can I generate it from the variable?
    2. Additionally, How do i change the time of 00:08:59 to 00:09:00?

    Thank you,
    Sarah
Working...
X