View source: R/estimate_coord_interval.R
estimate_coord_interval | R Documentation |
This function estimates a threshold in seconds that defines a coordinated link share. While it is common that multiple (pages/groups/account) entities share the same link, some tend to perform these actions in an unusually short period of time. Unusual is thus defined here as a function of the median co-share time difference. More specifically, the function ranks all co-shares by time-difference from first share and focuses on the behaviour of the quickest second share performing q% (default 0.5) URLs. The value returned is the median time in seconds spent by these URLs to cumulate the p% (default 0.1) of their total shares
estimate_coord_interval(
ct_shares.df,
q = 0.1,
p = 0.5,
clean_urls = FALSE,
keep_ourl_only = FALSE
)
ct_shares.df |
the data.frame of link posts resulting from the function get_ctshares |
q |
parameter that controls the quantile of quickest URLs to be filtered. Default to 0.1 [0-1] |
p |
parameter that controls the percentage of total shares to be reached. Default to 0.5 [0-1] |
clean_urls |
clean up unnecessary url paramters and malformed urls, and keep just the URLs included in the original data set (default FALSE) |
keep_ourl_only |
restrict the analysis to ct shares links matching the original URLs (default=FALSE) |
a list containing two objects: summary statistics of q% quickest second share performing URLs, and a time in seconds corresponding to the median time spent by these URLs to cumulate the p% of their total shares
cord_int <- estimate_coord_interval(ct_shares.df = ct_shares.df, q=0.1, p=0.5, clean_urls=TRUE, keep_ourl_only=FALSE)
cord_int[[1]]
cord_int[[2]]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.