rvkstat (version 2.6.3)

vkGetGroupStatAge: Community Statistics by User Age Bucket

Description

Load data about community visitors by age group (12-18, 18-21, 21-24, 24-27, 27-30, 30-35, 35-45, 45-100) on dates.

Usage

vkGetGroupStatAge(date_from = Sys.Date(), 
                  date_to = Sys.Date(), 
                  group_id = NULL, access_token = NULL)

Arguments

date_from

The starting date of the displayed statistics in the format YYYY-MM-DD.

date_to

The end date of the displayed statistics in the format YYYY-MM-DD.

group_id

Community ID.

access_token

API access token, obtained using the functions vkAuth or vkGetToken

Value

Date frame with statistics on community visitors with the following values:

1. Date

the date for which statistics are given.

2. Visitors

number of unique visitors.

3. AgeGroup

age interval.

Examples

Run this code
# NOT RUN {
## auth
my_tok <- vkAuth(app_id = 1,app_secret = "H2Pk8htyFD8024mZaPHm")

## Get statistics on age groups of visitors
communityDataAge <- vkGetGroupStatAge(date_from = "2016-01-01",
                                      date_to = "2016-04-01",
                                      group_id = 1,
                                      access_token = my_tok$access_token)
# }

Run the code above in your browser using DataCamp Workspace