This file contains 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
| common | rare | epic | legendary | g.common | g.rare | g.epic | g.legendary | | |
| ---- | ---- | ---- | ---- | -------- | -------- | -------- | -------- | | |
| 4 | 1 | | | | | | | | |
| 4 | 1 | | | | | | | | |
| 3 | 2 | | | | | | | | |
| 4 | 1 | | | | | | | | |
| 4 | 1 | | | | | | | | |
| 3 | | 1 | 1 | | | | | | |
| 4 | 1 | | | | | | | | |
| 4 | 1 | | | | | | | |
This file contains 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(Rcpp) | |
library(ggplot2) | |
library(dplyr) | |
opt = theme(legend.position = "none", | |
panel.background = element_rect(fill="white"), | |
axis.ticks = element_blank(), | |
panel.grid = element_blank(), | |
axis.title = element_blank(), | |
axis.text = element_blank()) |
This file contains 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
# first need to `chmod a+rx hugo-build.sh` | |
# inside a root directory: | |
rm -rf public | |
hugo --verbose | |
hugo server --gc -D --verbose --watch | |
# inside a theme, aim to serve an exampleSite: | |
# cd exampleSite | |
# hugo server --gc -D -t ../.. |
This file contains 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(tidyverse) | |
library(gganimate) | |
library(ggthemes) | |
df <- read_csv("pd.csv") %>% | |
select(-c("Day")) %>% | |
rename("Email" = `Email Inbox`, | |
"RIL" = `Reeder Read it Later`, | |
"Podcasts" = `Podcasts Episodes`, | |
"YouTube" = `YouTube Watch Later`) %>% |
This file contains 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
[{"time": 1514782800, "summary": "Clear throughout the day.", "icon": "clear-day", "sunriseTime": 1514809280, "sunsetTime": 1514842810, "moonPhase": 0.48, "precipIntensity": 0, "precipIntensityMax": 0, "precipProbability": 0, "temperatureHigh": 18.39, "temperatureHighTime": 1514836800, "temperatureLow": 12.23, "temperatureLowTime": 1514894400, "apparentTemperatureHigh": 17.29, "apparentTemperatureHighTime": 1514844000, "apparentTemperatureLow": 4.51, "apparentTemperatureLowTime": 1514887200, "dewPoint": -1.67, "humidity": 0.54, "pressure": 1028.26, "windSpeed": 4.16, "windGust": 13.98, "windGustTime": 1514829600, "windBearing": 309, "cloudCover": 0.02, "uvIndex": 2, "uvIndexTime": 1514822400, "visibility": 10, "temperatureMin": 6.17, "temperatureMinTime": 1514808000, "temperatureMax": 18.39, "temperatureMaxTime": 1514836800, "apparentTemperatureMin": -2.19, "apparentTemperatureMinTime": 1514808000, "apparentTemperatureMax": 17.29, "apparentTemperatureMaxTime": 1514844000, "date": "2018-01-01"}, {"time": 15148 |
This file contains 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(tidyverse) | |
library(gganimate) | |
library(janitor) | |
library(gapminder) | |
df <- gapminder %>% | |
janitor::clean_names() %>% | |
group_by(year) %>% | |
mutate(rank = rank(-life_exp), | |
Value_rel = life_exp/life_exp[rank==1], |
This file contains 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
# remove non-ascii characters | |
df$text <- gsub("[^\x20-\x7E]", "", df$text) |
This file contains 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
{"lastUpload":"2020-11-19T03:01:40.792Z","extensionVersion":"v3.4.3"} |
This file contains 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
import random | |
legit = 0 | |
while legit != 1: | |
x = eval(input("How much money do you like to put in the red pocket? ")) | |
y = eval(input("How many red pockets would you like to send? ")) | |
if x < y * 0.01: | |
print('Not enough money to send, sorry!') |
This file contains 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(rjags) | |
library(coda) | |
library(mcmcplots) | |
# 2015-2016 Premier League result table | |
# data source: https://github.com/vijinho/epl_mysql_db/blob/master/csv/E0-2015.csv | |
dat <- read.csv("E0-2015.csv") | |
head(dat) | |
dat <- dat[,3:6] |