Reputation: 19
I am trying to create a calculated field, which would be used in Data Studio like that(data would be from GA Events):
I would like to have as a calculated field in a time series:
Event Value of (Event Category: Economy, Event Action: Wallet Credits Changed, Event Label: game_session_bet)
+
Event Value of (Event Category: Economy, Event Action: Wallet Credits Changed, Event Label: game_session_win)
So basically a sum of those two event values.
Upvotes: 1
Views: 6042
Reputation: 859
You can't mix metrics and dimensions in a calculated field, so you need to make a calculated field dimension and use that in a filter.
Your field: game_session
CASE WHEN
(Event Value = 'Economy') AND (Event Action = 'Wallet Credits Changed') AND (Event Label in ('game_session_bet','gam_session_win')) then 'game_session'
ELSE 'other
END
Then make a filter where 'game_session' equals 'game_session' and make a chart with Event Value as the metric.
Upvotes: 1