vkGetGroupStat: Statistics on visiting the community in 'Vkontakte'.

Description Usage Arguments Value Author(s) References Examples

View source: R/vkGetGroupStat.R

Description

Load data from the 'Vkontakte' communities by the number of views, subscriptions, replies and community visitors by date.

Usage

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
vkGetGroupStat(
    date_from    = Sys.Date() - 7, 
    date_to      = Sys.Date(), 
    group_id     = NULL, 
    interval     = "day",
    intervals_count = NULL,
    filters      = NULL,
    stats_groups = c("visitors", "reach", "activity"),
    username     = getOption("rvkstat.username"),
    api_version  = getOption("rvkstat.api_version"),
    token_path   = vkTokenPath(),
    access_token = getOption("rvkstat.access_token")
)

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.

interval

Time intervals. Possible values: day, week, month, year, all.

intervals_count

Number of time intervals.

filters

A list of words separated by commas

stats_groups

Filter for getting data on a specific block of community statistics. Possible values: visitors, reach, activity.

username

Your vkontakte login.

api_version

Vkontakte API version.

token_path

Path to dir with credentials

access_token

API access tokens obtained using vkAuth or vkGetToken functions

Value

Date frame with community statistics with the following values:

1. day

date for which statistics is given.

2. views

number of views.

3. visitors

number of unique visitors.

4. total_reach

full coverage.

5. subscribers_reach

subscribers reach.

6. subscribed

number of new subscribers.

7. unsubscribed

number of unsubscribed.

Author(s)

Alexey Seleznev

References

Documentation for API method stats.get: https://vk.com/dev/stats.get

Examples

1
2
3
4
5
6
7
## Not run: 
## Getting community statistics
communityData <- vkGetGroupStat(date_from = "2021-01-01",
                               date_to = "2021-01-12",
                               group_id = 1)

## End(Not run)

rvkstat documentation built on Oct. 18, 2021, 5:07 p.m.