0

Super R noob here trying to get away with some copy/paste from Google. Any help to eliminate this error is appreciated.

here is my code:

library(bupaR)
library(dplyr)

data %>%
    # rename timestamp variables appropriately
   dplyr::rename(start = Starttime, 
         complete = Endtime) %>%
    # convert timestamps to 
    convert_timestamps(columns = c("start", "complete"), format = ymd_hms) %>% 
    activitylog(case_id = "Shipasitem",
                activity_id = "OperationDescription",
                timestamps = c("start", "complete"))

and here is the error:

Error in UseMethod("rename") : no applicable method for 'rename' applied to an object of class "function" Calls: %>% ... convert_timestamps -> stopifnot -> %in% -> Execution halted

i've tried calling all sorts of different libraries with no luck.

  • 1
    This suggests that you don't have a data frame named `data` (there is a function called `data` which is why you get the warning). Double check your spelling, including capitals. – Allan Cameron Jan 03 '23 at 19:18

0 Answers0