This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # remotes::install_github(c('yonicd/reactor@73c6285','yonicd/puzzlemath@17def58')) | |
| library(reactor) | |
| library(puzzlemath) | |
| obj1 <- init_reactor()%>% | |
| set_golem_args(package_name = 'puzzlemath')%>% | |
| set_chrome_driver( | |
| chromever = chrome_version() | |
| )%>% | |
| start_reactor() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(whereami) | |
| library(ggplot2) | |
| if(!file.exists('cars.csv')){ | |
| readr::write_csv(mtcars,path = 'cars.csv') | |
| } | |
| # Define the UI | |
| ui <- fluidPage( | |
| sidebarLayout( |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(shiny) | |
| library(shinyAce) | |
| modes <- getAceModes() | |
| themes <- getAceThemes() | |
| init <- "createData <- function(rows) { | |
| data.frame(col1 = 1:rows, col2 = rnorm(rows)) | |
| }" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(xml2) | |
| library(rvest) | |
| library(glue) | |
| library(dplyr) | |
| library(purrr) | |
| library(purrrogress) | |
| library(ggmap) | |
| library(ggplot2) | |
| srm <- function(x,pat = '\\t+|\\n+',replace = '') gsub(pat,replace,x) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(magrittr) | |
| library(rtweet) | |
| root_status <- '1116361675618361345' | |
| x1 <- rtweet::lookup_tweets(root_status) | |
| # The question | |
| cat(x1$text) | |
| #> Who do you: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| runloc <- function(path_expand = FALSE){ | |
| src <- 'Untitled' | |
| if(rstudioapi::getActiveDocumentContext()$id=='#console') | |
| src <- 'Console' | |
| if(length(getSrcFilename(sys.call(sys.nframe()-1)))>0) | |
| src <- file.path( | |
| getSrcDirectory(sys.call(sys.nframe()-1)), |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| remotes::install_github('yonicd/ghnet') | |
| library(ghnet) | |
| # get current github R repos using gepuro json file | |
| universe <- fetch_gepuro() | |
| # filter to ropenscilabs repos only | |
| ropenscilabs_repos <- universe%>% | |
| dplyr::filter(owner=='ropenscilabs')%>% |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| license: mit |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(rtweet) | |
| library(slickR) # remotes::install_github('metrumresearchgroup/slickR') | |
| tweets <- rtweet::search_tweets("#rstats", n = 5, include_rts = FALSE) | |
| # https://github.com/mkearney/rtweet/pull/305/files | |
| tweet_embed <- function(screen_name,status_id,...){ | |
| stem <- 'https://publish.twitter.com/oembed' | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| library(rvest) | |
| library(patchwork) | |
| tweet_threading <- function(tw){ | |
| last_found <- FALSE | |
| while(!last_found){ | |
| nr <- nrow(tw) | |
| last_found <- is.na(tw$reply_to_status_id[nr]) |
NewerOlder