I have a dataframe where I have a column which has value of runtime as "70 min" or "1 hr 30 Min" and N/A etc. I want to convert these values to numeric, like 70 min should be 70 and 1 hr 30 minutes should be 90. Also, I want to Keep N/A as it is.
a<- c("70 min", "1 hr 30 Min")
typeof(a)
a <- as.numeric(a)
when I tried as.numeric, it converted everything to NA, some experiments with lubridate package also disappointed me. Any expert advice please.