sum_visits()
summarizes the number of visits by person within a timeframe
,
and optionally by visit_class
of visit.
Arguments
- wt
webtrack data object.
- timeframe
character. Indicates for what time frame to aggregate visits. Possible values are
"date"
,"week"
,"month"
,"year"
,"wave"
orNULL
. If set to"wave"
,wt
must contain a column callwave
. Defaults toNULL
, in which case the output contains number of visits for the entire time.- visit_class
character. Column that contains a classification of visits. For each value in this column, the output will have a column indicating the number of visits belonging to that value. Defaults to
NULL
.