This reference describes the method that you use to track periods of time in Google Analytics. The site speed user timing reports are designed specifically to help developers understand the latency, or time spent, making AJAX requests or loading web resources. Read the Site Speed User Timings Developer Guide for details describing how to use this method.
GATC User Timing Method
variable, time, opt_label, opt_sampleRate)
Constructs and sends the user timing tracking call to the Google Analytics Tracking Code. For example if the jQuery library took 20 milliseconds to load from the Google Content Network, and you wanted data to be sent for 50% of visitors, you would call:
_gaq.push([‘_trackTiming’, ‘jQuery’, ‘Load Library’, 20, ‘Google CDN’, 50]);
|A string for categorizing all
user timing variables into logical groups for easier reporting purposes.
For example you might use value of
jQuery if you
|A string to indicate the name
of the action of the resource being tracked. For example you might
use the value of
variables can be used across multiple categories to track timings for
an event common to these categories such as
Page Ready Time, etc.
|The number of milliseconds in elapsed
time to report to Google Analytics. If the jQuery library took 20
milliseconds to load, then you would send the value of
|A string that can be used to add
flexibility in visualizing user timings in the reports. Labels can also
be used to focus on different sub experiments for the same category and
variable combination. For example if we
loaded jQuery from the Google Content Delivery Network, we would use
the value of
|A number to manually
override the percent of visitors whose timing hits get sent to Google Analytics.
The default is set at the same number as general site speed data
collection and is based as a percentage of visitors. So if you wanted to track
_trackTiming hits for 100% of visitors, you would use the value
Note that each hit counts against the general 500 hits per session limit.