0

How are you?

Can you help me, please?

I imported a file in CSV with hours but when I use str() function it return that the hours is in CHR. I need to make several calculat with this hours like: mean, sum, divided, etc. However it is not possible 'cause the hours are in CHR.

The Following the command that I used:

Command:

library(readr)

time <- read.csv("time_total.csv", sep = ";")

str(time)

Return:

'data.frame': 9 obs. of 1 variable

$ V1: chr "57:16:00" "57:16:00" "57:16:00" "27:54:00" ...

Andrey
  • 1
  • 1
  • Welcome to SO! The package **lubridate** has plenty functions to convert times format to one another. Check the cheatsheet: https://raw.githubusercontent.com/rstudio/cheatsheets/master/lubridate.pdf – MonJeanJean Jun 29 '21 at 13:50

0 Answers0