Google Analytics User Activity showing wrong Event Parameters - firebase

After creating a report using the Explore (Analysis) tool on Google Analytics, we've created a report for all the users that have triggered a specific event. but once we click on that user to view his User's Activities, we found the following issues:
Numeric Event Parameters are being shown with 6 extra zeros. (i.e. actual value=5, shown value=5000000).
It is not showing all the Event Parameters that we are sending with the event
2 notes that should be mentioned:
at the same time, we've checked BigQuery for those records and saw that the number event parameters values are correct (without zeros) and all event parameters are being stored correctly.
the numeric Event parameter has been registered as Standard

Related

Google Data Studio can't count user count for an analytics event

So i've an app that logs events to firebase/google analytics for instance lets say the event name is 'log_purchase'
I can use data studio and create a filter but now if i select my metric as
event count i can see a value but if i change it to 'Active Users' as in total number of unique users that triggered this event
It says no data, what am i doing wrong how can i see either active user count or event count that only logs users once
Turns out it needs at least around 40-45 users before the data studio shows them after that it starts to work properly.

Firestore Analytics - Is there a limit to the number of parameter's values in one event?

So let's say for example, I have user_id#1234 in chat room_id#4321 and I'm keeping track of:
The total number of messages for this particular room_id#4321, and
The total number of messages user_id#1234 sends in this room - (It's important to associate the user's messages with the room because I need to track the total user's message count PER each chat room.)
Here's the approach I got so far in my attempt to keep it to one event: On Firestore Analytics, I've created a custom dimension with the event "room_messages" and I'm able to log the events like so every time a message is sent:
firebase
.analytics()
.logEvent("room_messages", {
room_id: room_id,
user_room: `${user_id}-${room_id}`,
});
But particularly for the user_room parameter, since there could be so many users and rooms, is there a limit on the number of parameter values? ie there could be a ton of the event (room_messages) -> parameter (user_room) -> value (user_id-room_id)
And on top of that, how do you even view these events and their parameters for insights? Whether on Firestore or Google Analytics, it seems like I can view all the total events that have occurred just fine, but for viewing the events AND their parameters, I am only able to view that from what events were triggered in the last 30 minutes.
Appreciate any help!
Update: The parameter has to also be defined using Custom Definitions. Now the room_id tracking information shows up on the room_messages event page.

Google Calendar API V3: Identifying edited one-offs of recurring events?

I am currently listing all events from a Google Calendar using the "singleEvents" parameter set to true, which splits recurring events into individual events – which is good. However, I'm running into an issue when an instance of a recurring event is edited, and the edits are saved with the "Only this event" option in the Calendar UI.
What I need to do is be able to identify which of these recurring event instances have been edited, and which have not. It seems the API response data does not provide any indications of whether this is an instance of the unedited recurring event, or an edited one-off. The response for an unedited instance of a recurring event and an edited instance are more-or-less the same, save the description field, which was edited.
The reason I need to differentiate edited versus unedited recurring event instances is that I am dynamically creating event detail pages from the list of single events. I would like to have one page be for the recurring event itself, and another for a "one-off" of that recurring event. E.g:
allmyevents.com/events/my-recurring-event --> page showing recurring event with recurrence information
allmyevents.com/events/my-recurring-event/16-4-2020 --> page showing specific instance of recurring event, which has been edited
Currently, I'm able to do this by creating an entirely new event at the same date and with the same title as the recurring event instance I want to replace, and writing hacky comparison logic to tell if this is a replacement event, but this is counter-intuitive for event/content management.
Answer:
You can use the Calendar API Events: instances endpoint to return all instances of a recurring event. All the events which have been edited on their own will not be returned.
More Information:
The Events: instances endpoint of the Calendar API will return all instances of a recurring event for a calendarId and eventId specified. Any of these that have been edited are omitted.
It's a bit of a workaround, as these events can't be obtained directly, but by obtaining the list of events as you have already been doing and then removing the events which are returned by Events: instances, you can build a list of all the events which have been edited with the 'Only this event' option.
Psuedo-code:
You can do something like this:
eventsList = Calendar.Events.List(calendarId, singleEvents=true)
eventsInstances = Calendar.Events.Instances(calendarId, recurringEventId)
singleEvents = eventsList
for each instance in eventsInstances :
if eventsList.items contains instance :
singleEvents.remove(instance)
return singleEvents
Where the returned singleEvents variable will be a list of all the events that have been edited manually.
References:
Events: instances | Calendar API | Google Developers
Recurring Events | Calendar API | Google Developers
I've been puzzling through this same issue, and I think I've found a way forward that doesn't involve going through every single instance to check if they've been moved/edited:
Each event returned by the Calendar API has an iCalUID field. For a standalone event, this should match the event's id, with an #google.com suffix. e.g. an event with the id of abcdef has an iCalUID of abcdef#google.com.
When it comes to recurring series, every single instance of that event has the same iCalUID value - and, most importantly, you can use iCalUID as a filter when listing events, which will return the main recurring series event and all modified instances. Unmodified instances are not returned.
Tracking which instances have been deleted is slightly more fiddly. They might be returned in the list with the matching iCalUID, but with a status set to cancelled. Or, they may be specified within the recurrence property (an array of strings) on the main series event as timestamps (within the given time-zone, which should match whichever time-zone the main series event uses):
[
"RRULE:FREQ=WEEKLY,COUNT=5",
"EXDATE;TZID=Australia/Melbourne:20211227T110000,20220103T110000"
]
I haven't figured out why some recurring events use the specific-instances-as-cancelled approach, and others use the EXDATE approach (and I think they can also be combined, so don't presume the presence of one rules out the other). Given both are possible, you'll have to allow for that.

Report last login by user on Google Analytics

What would be the easiest way to get a report on Google Analytics containing authenticated users ordered by the last login time (the latest login first)?
We are already using Event logging with Category "User", Action "Login" and Label set to user ID (a GUID). Is it possible to base the report on this data?
UPDATE 5-Dec-2018:
As a reference, we have a Custom Report for top logins:
This shows:
Now, I would like to change 'Hits' to "the last time the event occurred", with the given Event Label.
You can create a custom report with the event label ordered by date and time. Though the default implementation in GA only gives you up to the hours I believe. If you want more granularity, I think you'd need to create a custom dimension with a timestamp to the second/millisecond and capture that data front-end.

Google Analytics: How to associate an event with an individual session

I have a variable that's being laoded on my page and then being reported back to GA via the event tracking api. Is there a way for this "event" to be associated with the flow of an individual session?
For example: If I have a variable that gets reported as "eligible", can I then associate this event with the session and page flows?
Yes, you can create an advanced segment. That is a way to filter sessions (visits) according to certain criteria. In this case, your criterion would be "Include: Event Label = 'the name of the label of your event'".
Note that it is against the terms of use of GA though to report data on an indidivual basis, i.e. it is not allowed to create an event label that allows you to identify each single session.

Resources