View source: R/remarketingAudiences.R
ga_remarketing_create | R Documentation |
Create a remarketing audiences built via ga_remarketing_build
ga_remarketing_create(
adwordsLinkId,
include,
exclude = NULL,
audienceType = c("SIMPLE", "STATE_BASED"),
name = NULL
)
adwordsLinkId |
The adwords link to add the remarketing audience to |
include |
A |
exclude |
If |
audienceType |
|
name |
An optional name, if not supplied one will be generated |
This builds and calls the API to create the remarketing audience based on the segments you have defined.
Other remarketing management functions:
ga_remarketing_build()
,
ga_remarketing_estimate()
,
ga_remarketing_get()
,
ga_remarketing_list()
## Not run:
adword_list <- ga_adwords_list(123456, "UA-123456-1")
adword_link <- ga_adword(adword_list$id[[1]])
segment_list <- ga_segment_list()$items$definition
my_remarketing1 <- ga_remarketing_build(segment_list[[1]],
state_duration = "TEMPORARY",
membershipDurationDays = 90,
daysToLookBack = 14)
my_remarketing2 <- ga_remarketing_build(segment_list[[2]],
state_duration = "PERMANENT",
membershipDurationDays = 7,
daysToLookBack = 31)
# state based only can include exclusions
ga_remarketing_create(adwords_link = adword_link,
include = my_remarketing1,
exclude = my_remarketing2,
audienceType = "STATE_BASED",
name = "my_remarketing_seg1")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.