Learn R Programming

vosonSML (version 0.29.10)

Create.activity.twitter: Create twitter activity network

Description

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.

Usage

# S3 method for activity.twitter
Create(datasource, type, 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".

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

Run this code
# NOT RUN {
# create a twitter activity network graph
activityNetwork <- twitterData %>% Create("activity")
  
# network
# activityNetwork$nodes
# activityNetwork$edges
# }
# NOT RUN {
# }

Run the code above in your browser using DataLab