0

I have a date set where the hour of purchase is given as a proportion of 24 hours, so 0.5 is noon for example.

Now, I want to convert these proportions into a normal time with hours:minutes. Does anyone know how to achieve this?

Thanks in advance!

Panda
  • 11
  • 2
  • Does this answer your question? [Convert decimal hours to HH:MM:SS](https://stackoverflow.com/questions/19721145/convert-decimal-hours-to-hhmmss) – Andrea M Jul 08 '22 at 20:55
  • Also see this recent question: https://stackoverflow.com/questions/72910524/julian-day-time-to-military-time-r#comment128778813_72910524 – Dave2e Jul 08 '22 at 21:31

1 Answers1

0

Does this solve your problem?

library(lubridate)
as.period(ddays(fraction))
dcsuka
  • 2,922
  • 3
  • 6
  • 27