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(dplyr) | |
library(stringr) | |
base_url = "http://www.basketball-reference.com/play-index/tscore.cgi?request=1&match=combined&" | |
post_fix_1 = "is_playoffs=N&order_by=pts" | |
post_fix_rest = "year_min=1955&year_max=2017&team_id=&opp_id=&quarter_is_1=&quarter_is_2=&quarter_is_3=&quarter_is_4=&quarter_is_5=&is_playoffs=N&round_id=&game_num_type=&game_num_min=&game_num_max=&game_month=&game_location=&game_result=&is_overtime=&c1stat=&c1comp=&c1val=&c2stat=&c2comp=&c2val=&c3stat=&c3comp=&c3val=&order_by=pts&order_by_asc=&offset=" | |
vec_url = c(paste0(base_url, post_fix_1), | |
paste0(base_url, post_fix_rest, seq(from = 100, to = 110000, by = 100))) |
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
# Based on the Gist by @hrbrmstr https://gist.github.com/hrbrmstr/b91752d32a07ee8595db33babe735b6b | |
library(httr) | |
library(leaflet) | |
GET("https://ipinfo.io/json") %>% # get IP geolocated coordinates | |
content() %>% | |
.$loc %>% | |
strsplit(",") %>% | |
.[[1]] %>% | |
as.numeric() -> lat_lng |
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(tweenr) # Available on CRAN | |
library(ggforce) # Install from thomasp85/ggforce | |
library(gganimate) # Install from dgrtwo/gganimate | |
set.seed(2) | |
x <- sample(9,20, prob=c(1,2,3,4,5,4,3,2,1), replace=T) | |
df <- data.frame(x = x, y = 15) | |
dfs <- list(df) | |
for(i in seq_len(nrow(df))) { | |
dftemp <- tail(dfs, 1) | |
dftemp[[1]]$y[i] <- sum(dftemp[[1]]$x[seq_len(i)] == dftemp[[1]]$x[i]) |
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
D14B3609D1A4497B88117CE30425F20E | |
EXPLANATORY MEMORANDUM | |
1. CONTEXT OF THE DELEGATED ACT | |
1.1 General background and objectives |
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
# Adjusted bash for building in Atlassian Bamboo | |
# | |
# See README.md for instructions, or for more configuration options, | |
# see the wiki: | |
# https://github.com/craigcitro/r-travis/wiki | |
curl -OL http://raw.github.com/craigcitro/r-travis/master/scripts/travis-tool.sh | |
chmod 755 ./travis-tool.sh | |
./travis-tool.sh bootstrap | |
./travis-tool.sh install_deps |
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
require(digest) | |
require(shiny) | |
ui <- basicPage( | |
uiOutput("register"), | |
actionButton("doRegister",label="Register"), | |
verbatimTextOutput("resultRegister"), | |
uiOutput("login"), |
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
require(shiny) | |
ui <- basicPage( | |
numericInput("test", "Input Number", value=2, min=0, max=5), | |
verbatimTextOutput("test_regression"), | |
tableOutput("session_info"), | |
tableOutput("shiny_info"), | |
verbatimTextOutput("test_alpha"), | |
tableOutput("test_df") |