Returns a JSON string defining a function to be used to build a calculated (derived) metric.
Usage
cm_function(
func = "col-sum",
metric = "visits",
dimension = NULL,
seg_filter = NULL,
rsid = Sys.getenv("AW_REPORTSUITE_ID"),
company_id = Sys.getenv("AW_COMPANY_ID")
)Arguments
- func
Calculated function id. Only Basic single metric functions are able to be used.
- metric
The metric to be used in the functional metric calculation. Default is
visits- dimension
The dimension to be used in the functional metric calculation. Default is
NULL- seg_filter
A segment filter to be added to a metric in the formula
- rsid
Adobe report suite ID (RSID). If an environment variable called
AW_REPORTSUITE_IDexists in.Renvironor elsewhere and norsidargument is provided, then theAW_REPORTSUITE_IDvalue will be used. Useaw_get_reportsuites()to get a list of availablersidvalues.- company_id
Company ID. If an environment variable called
AW_COMPANY_IDexists in.Renvironor elsewhere and nocompany_idargument is provided, then theAW_COMPANY_IDvalue will be used. Useget_me()to get a list of availablecompany_idvalues.
