A helper function to aggregate over dimensions
aggregateGAData(ga_data, agg_names = NULL,
mean_regex = "^avg|^percent|Rate$|^CPC$|^CTR$|^CPM$|^RPC$|^ROI$|^ROAS$|Per")
A dataframe of data to aggregate
The columns to aggregate over
The regex for column names to do mean() rather than sum()
Will auto select metrics if they are numeric class columns.
Will auto perform mean aggregation it metric names match mean_regex
argument
If agg_names is NULL will aggregate over all