RDAdams / tuber

:sweet_potato: Access YouTube from R

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

🍠 tuber: Access YouTube API via R

Build status Build Status CRAN_Status_Badge

Access YouTube API via R. Get comments posted on YouTube videos, information on how many times a video has been liked, search for videos with particular content, and much more. You can also scrape captions from a few videos. To learn more about the YouTube API, see https://developers.google.com/youtube/v3/.

Installation

To get the current development version from GitHub:

# install.packages("devtools")
devtools::install_github("soodoku/tuber", build_vignettes = TRUE)

To get a quick overview of some important functions in tuber, see the vignette:

vignette("tuber-ex", package="tuber")

Using tuber

To get going, get the application id and password from Google Developer Console (see https://developers.google.com/youtube/v3/getting-started). Enable all the YouTube APIs. Also enable Freebase API. Then set the application id and password via the yt_oauth function. For more information about YouTube OAuth, see YouTube OAuth Guide.

yt_oauth("app_id", "app_password")

Get Statistics of a Video

get_stats(video_id="N708P-A45D0")

Get Information About a Video

get_details(video_id="N708P-A45D0")

Get Captions of a Video

get_captions(video_id="yJXTXN4xrI8")

Search Videos

yt_search("Barack Obama")

Search Videos by Topic Uses the Freebase database of topics.

yt_topic_search("Barack Obama")

Get Comments

get_comments(video_id="N708P-A45D0")

License

Scripts are released under the MIT License.

About

:sweet_potato: Access YouTube from R

License:Other


Languages

Language:R 100.0%