Description Usage Arguments Value
GET data from the Analytic API
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | analytic(
format = c("csv", "json"),
perspective = c("rank", "interval"),
resolution_time = c("minute", "hour", "day", "week", "month"),
restrict_begin = lubridate::floor_date(Sys.Date(), "week"),
restrict_end = Sys.Date(),
restrict_kind = c("overview", "category", "activity", "productivity", "document",
"efficiency"),
restrict_thing = NULL,
restrict_thingy = NULL,
restrict_source_type = c("computers", "mobile", "offline"),
restrict_schedule_id = NULL,
key = get_key()
)
|
format |
'csv' | 'json' |
perspective |
Consider this the X - axis of the returned data. It is what determines how your data is crunched serverside for ordered return.
|
resolution_time |
Default is "hour". In an interval report, the X axis unit. In other words, data is summarizd into chunks of this size. "minute" will return data grouped into five-minute buckets, which is the most granular view available. |
restrict_begin |
Sets the start day for data batch, inclusive (always at time 00:00, start hour/minute not supported) Format ISO 8601 "YYYY-MM-DD" |
restrict_end |
Sets the end day for data batch, inclusive (always at time 00:00, end hour/minute not supported) Format ISO 8601 "YYYY-MM-DD" |
restrict_kind |
Allows you to preprocess data through different statistical engines. The perspective dictates the main grouping of the data, this provides different aspects of that main grouping.
|
restrict_thing |
The name of a specific overview, category, application or website. For websites, use the domain component only if it starts with "www", eg. "www.nytimes.com" would be "nytimes.com". |
restrict_thingy |
Refers to the specific "document" or "activity" we record for the currently active application, if supported. For example, the document name active when using Microsoft Word. Available for most major applications and web sites. Let us know if yours is not. |
restrict_source_type |
Allows for querying by source device type. |
restrict_schedule_id |
Allows for filtering results by schedule. |
key |
Your API key (retrieved automatically if stored in .Renviron) OR |
(data.frame/list)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.