Creates a twitter activity network from collected tweets. Nodes are tweets and directed edges represent the relationship of tweets to one another. For example, there is a directed edge from a quote tweet towards the tweet that was quoted. Stand-alone tweets that are not replies, retweets or quote tweets have no relation to others and will be isolates.

# S3 method for activity2.twitter
Create(datasource, type, rmNodeTypes = NULL, verbose = TRUE, ...)

Arguments

datasource

Collected social media data with "datasource" and "twitter" class names.

type

Character string. Type of network to be created, set to "activity".

rmNodeTypes

Character vector. List of tweet types to remove from network. Options are "tweet", "retweet", "reply" and "quote". Default is NULL.

verbose

Logical. Output additional information about the network creation. Default is TRUE.

...

Additional parameters passed to function. Not used in this method.

Value

Network as a named list of two dataframes containing $nodes and $edges.

Examples

if (FALSE) { # create a twitter activity network with retweets removed activity_net <- twitter_data %>% Create("activity2", rmNodeTypes = c("retweet")) # network nodes and edges # activity_net$nodes # activity_net$edges }