Create a Google Analytics variable selector
Shiny Module for use with GA4 metric and dimension fields fetched via ga_meta("ga4")
metricDimensionSelectUI(id, label = "Metric", multiple = TRUE, width = NULL)metricDimensionSelect(
id,
field_type = c("metric", "dimension"),
custom_meta = NULL,
default = NULL
)
Shiny UI
the selected variable
The Shiny id
label
multiple select
width of select
metric or dimension
Pass a meta field table from ga_meta("ga4")
to get custom fields from GA4 (reactive)
The default selected choice. First element if NULL
Other Shiny modules:
accountPickerUI()
,
authDropdown()
,
authDropdownUI()
,
multi_select()
,
multi_selectUI()