rawr (version 0.1.0)

github: Retrieve raw R code from an .R file hosted on github website

Description

Retrieve raw R code from an .R file hosted on github website

Usage

github(url)

Arguments

url

Link to an R file on github website

Value

A character vector of length 1 containing the R code from the target url. All code at the target url (including javascript, ruby, python) will be returned.

Examples

Run this code
# NOT RUN {
library(dplyr)
github("https://github.com/hadley/vis-eda/blob/master/travel.R")

# Same as above but provided to cat for easy viewing
github("https://github.com/hadley/vis-eda/blob/master/travel.R") %>%
  cat


# }

Run the code above in your browser using DataCamp Workspace