NEWS.md
vctrs error when using dplyr functions. The classes are no longer needed post-method routing so they are simply removed.dplyr::funs function that was generating a warning.Create.semantic.twitter and Create.twomode.twitter functions using the tidytext package. They now better support tokenization of tweet text and allows a range of stopword lists and sources to be used from the stopwords package. The semantic network function requires the tidytext and tidyr packages to be installed before use.Create.semantic.twitter:
removeNumbers and removeUrls, default value is TRUE.assoc parameter has been added to choose which node associations or ties to include in the network. The default value is "limited" and includes only ties between most frequently occurring hashtags and terms in tweets. A value of full will also include ties between most frequently occurring hashtags and hashtags, and terms with terms creating a more densely connected network.stopwords language e.g stopwordsLang = "en" and source e.g stopwordsSrc = "smart" have been added. These correspond to the language and source parameters of the tidytext::get_stopwords function. The stopwords default value is TRUE.Create.twomode.twitter function is weighted by default but can be disabled by setting the new weighted parameter to FALSE.replies_from_text parameter to repliesFromText and at_replies_only to atRepliesOnly in the AddText.actor.youtube function for consistency.tm package dependency.Introduction to vosonSML vignette Merging Collected Data examples.Collect.youtube that was causing no video comments to be collected if there were no reply comments for any of the videos first maxComments number of top level comments. For example, if maxComments is set to 100 and the first 100 comments made to a video had no replies then no results would be returned.rtweet::rate_limit function that resulted in an error when using the rtweet retryonratelimit search parameter. The rate_limit function was being called by vosonSML to check the twitter rate limit regardless of whether the search parameter was set or not, and so was failing Collect with an error. A fix was made so that vosonSML checks if rtweet::rate_limit succeeds, and if not automatically sets retryonratelimit to FALSE so that a twitter Collect can still be performed without error should this problem occur again.jsonlite::fromJSON.tictoc package from dependency imports to suggested packages.rtweet package is installed.RedditExtractoR package from imports.twomode networks.reddit gsub locale error https://github.com/vosonlab/vosonSML/issues/21.bimodal network hashtags to lowercase as filter terms when entered are converted to lowercase.bimodal and semantic networks.GetVideoData() function call in AddVideoData.AddText functions related to strict typing by dplyr::if_else function.AddText function to redirect edges towards actors based on the presence of a screen name or @screen name that may be found at the beginning of a reply comment. Typically reply comments are directed towards a top-level comment, this instead captures when reply comments are directed to other commenters in the thread.actor network identifiers to be their unique Channel ID instead of their screen names.AddVideoData function to add collected video data to the youtube actor network. The main purpose of this function is to replace video identifiers with the Channel ID of the video publisher (actor) instead. To get the Channel ID of video publishers an additional API lookup for the videos in the network is required. Additional columns such as video Title, Description and Published time are also added to the network $edges dataframe as well as returned in their own dataframe called $videos.AddText function to add collected text data to networks. This feature applies to activity and actor networks and will typically add a node attribute to activity networks and an edge attribute to actor networks. For example, this function will add the column vosonTxt_tweets containing tweet text to $nodes if passed an activity network, and to $edges if passed an actor network.igraph graph objects and subsequent writing to file has been removed from the Create function and placed in a new function Graph. This change abstracts the graph creation and makes it optional, but also allows supplemental network steps such as AddText to be performed prior to creating the final igraph object.writeToFile parameter from Create functions and added it to Graph.weightEdges, textData and cleanText parameters from Create.actor.reddit. cleanText is now a parameter of AddText.activity.reddit and AddText.actor.reddit.AddTwitterUserData with AddUserData function that works similarly to AddText. This function currently only applies to twitter actor networks and will add, or download add if missing, user profile information to actors as node attributes.rtweet::create_token. Method is used when only twitter app name and consumer keys are passed to Authenticate.twitter as parameters. e.g Authenticate("twitter", appName = "An App", apiKey = "xxxxxxxxxxxx", apiSecret = "xxxxxxxxxxxx"). A browser tab will open asking the user to authorize the app to their twitter account to complete authentication. This is using twitters Application-user authentication: OAuth 1a (access token for user context) method.file) via the HTTPUserAgent option. It is temporarily set to package name and current version number for Collect e.g vosonSML v.0.27.2 (R Package).Create.semantic.twitter in which a sum operation calculating edge weights would set NA values for all edges due to NA values present in the hashtag fields. This occurs when there are tweets with no hashtags in the twitter collection and is now checked.Create.semantic.twitter were also fixed.Collect.twitter in which any additional twitter API parameters e.g lang or until were not being passed properly to rtweet::search_tweets. This resulted in the additional parameters being ignored.SaveCredential and LoadCredential functions, as well as the useCachedToken parameter for Authenticate.twitter. These were simply calling the saveRDS and readRDS functions and not performing any additional processing. Using saveRDS and readRDS directly to save and load an Authenticate credential object to file is simpler.cleanText parameter works in Create.actor.reddit so that it is more permissive. Addresses encoding issues with apostrophes and pound symbols and removes unicode characters not permitted by the XML 1.0 standard as used in graphml files. This is best effort and does not resolve all reddit text encoding issues.Collect.twitter summary information that includes the earliest (min) and latest (max) tweet status_id collected with timestamp. The status_id values can be used to frame subsequent collections as since_id or max_id parameter values. If the until date parameter was used the timestamp can also be used as a quick confirmation.Collect method.Create.actor.twitter and Create.bimodal.twitter in which the vertices dataframe provided to the graph_from_data_frame function as a contained duplicate names raising an error.twitteR twitter collection implementation with the rtweet package.twitter authentication token can now be cached in the .twitter_oauth_token file and used for subsequent twitter API requests without re-authentication. A new authentication token can be cached by deleting this file and using the re-using the parameter useCachedToken = TRUE.