funnel_start: Start a funnel

Description Usage Arguments Examples

View source: R/sequence_funnel.R

Description

Start a funnel

Usage

1
funnel_start(tbl, moment_type, moment, tstamp, user)

Arguments

tbl

A table of different moments and timestamps

moment_type

The first moment in the funnel

moment

The name of the column with the moment_type

tstamp

The name of the column with the timestamps of the moments

user

The name of the column indicating the user who did the moment

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
library(dplyr)

activity <- tibble::tribble(
  ~ "user_id", ~ "event", ~ "timestamp",
  1, "landing", "2019-07-01",
  1, "registration", "2019-07-02",
  1, "purchase", "2019-07-07",
  1, "purchase", "2019-07-10",
  2, "landing", "2019-08-01",
  2, "registration", "2019-08-15",
  3, "landing", "2019-05-01",
  3, "registration", "2019-06-01",
  3, "purchase", "2019-06-04",
  4, "landing", "2019-06-13")

activity %>%
  funnel_start(moment_type = "landing",
               moment = "event",
               tstamp = "timestamp",
               user = "user_id")

datacamp/funneljoin documentation built on June 18, 2020, 6:52 a.m.