R/activity_labels.R

Defines functions activity_labels.log activity_labels

Documented in activity_labels activity_labels.log

#' @title Get vector of activity labels
#' @description Retrieve a vector containing all unique activity labels
#' @inheritParams act_collapse
#' @export
activity_labels <- function(log, eventlog = deprecated()) {
	UseMethod("activity_labels")
}

#' @describeIn activity_labels Retrieve activity labels
#' @export
activity_labels.log <- function(log, eventlog = deprecated()) {

	log <- lifecycle_warning_eventlog(log, eventlog)

	log %>%
		ungroup() %>%
		pull(!!activity_id_(log)) %>%
		unique()
}

Try the bupaR package in your browser

Any scripts or data that you put into this service are public.

bupaR documentation built on April 3, 2023, 5:23 p.m.