Use stats::lag because dplyr::lag no longer exists