Description Usage Arguments See Also Examples
View source: R/custom_dims_mets.R
Modify existing custom dimensions
1 2 3 4 5 6 7 8 9 |
id |
The id of the custom dimension |
accountId |
AccountId of the custom dimension |
webPropertyId |
WebPropertyId of the custom dimension |
name |
Name of custom dimension |
active |
|
scope |
Scope of custom dimension - one of |
ignoreCustomDataSourceLinks |
Force the update and ignore any warnings related to the custom dimension being linked to a custom data source / data set. |
Custom dimensions support article
Other custom variable functions:
ga_custom_vars_create()
,
ga_custom_vars_list()
,
ga_custom_vars()
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | ## Not run:
library(googleAnalyticsR)
ga_auth()
# create custom var
ga_custom_vars_create("my_custom_dim",
index = 7,
accountId = 54019251,
webPropertyId = "UA-54019251-4",
scope = "HIT",
active = FALSE)
# view custom dimension in list
ga_custom_vars_list(54019251, webPropertyId = "UA-54019251-4", type = "customDimensions")
# change a custom dimension
ga_custom_vars_patch("ga:dimension7",
accountId = 54019251,
webPropertyId = "UA-54019251-4",
name = "my_custom_dim2",
active = TRUE)
# view custom dimensions again to see change
ga_custom_vars_list(54019251, webPropertyId = "UA-54019251-4", type = "customDimensions")
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.