Time between Values being set in a variable

Avatar

Avatar

MKEmark

Avatar

MKEmark

MKEmark

27-10-2017

How can I track how much time (in seconds) elapses between two events? I would like to look at the time between two different values being set in a variable (separate server call).  We are looking to do something similar to the TimeToComplete Plug-in described here:

https://blogs.adobe.com/digitalmarketing/analytics/plug-ins-inside-omniture-sitecatalyst/

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar

Gigazelle

Employee

Total Posts

1.9K

Likes

459

Correct Answer

734

Avatar

Gigazelle

Employee

Total Posts

1.9K

Likes

459

Correct Answer

734
Gigazelle
Employee

02-11-2017

Your best bet here is going to be using a cookie. Set a cookie with the timestamp when the first event is set, then when the second event fires, call the cookie and set a variable value based on the elapsed time.

  • If you plan to use this as a dimension, you can either use the value in seconds, or use additional logic to put them in buckets.
  • If you plan to use this as a metric, you can increment an event by the number of seconds that have elapsed. Recent appMeasurement libraries allow the format s.events="event1=10".

Answers (0)