Skip to content

Instantly share code, notes, and snippets.

Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@stedy
stedy / mbparks.geojson
Created April 7, 2022 23:07
Mt Baker parks geojson
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@stedy
stedy / pj_concert_archive.csv
Last active March 18, 2022 18:44
All Pearl Jam concerts post Ten release
date venue city stateprov
1991-08-29 RKCNDY Seattle WA
1991-09-03 RKCNDY Seattle WA
1991-09-25 Harpo's Victoria BC
1991-09-26 Town Pump Vancouver BC
1991-09-28 Satyricon Portland OR
1991-09-30 I-Beam San Francisco CA
1991-10-01 The Cathouse Los Angeles CA
1991-10-02 Troubadour Los Angeles CA
1991-10-05 Winter's San Diego CA
@stedy
stedy / ec2_setup.md
Created April 21, 2021 05:51
ec2_setup

#How to get up and running on AWS

  1. Go to aws.amazon.com and after logging in with your Amazon account (or creating a new Amazon account) click on the link for EC2.
  2. Click the button that says Launch Instance
  3. AWS will walk you through a step by step process of setting up your EC2 instance. Step 1 of choosing an EC2 instance is choosing a machine instance. There are many server options with different OS types but I primarily use a 64-bit ubuntu server with the most recent release.
  4. The next step is choosing an instance type. Generally I have found the bigger the instance the better and paying a few dollars is generally better than using the free tier. I have never
@stedy
stedy / all_championship_games_by_state.csv
Created February 4, 2021 22:37
All championship matchups by state complete for all 4 major professional sports
Year MLBstateA MLBstateB NBAstateA NBAstateB NFLstateA NFLstateB NHLstateA NHLstateB
1967 Missouri Massachusetts California Pennsylvania Wisconsin Missouri Canada Canada
1968 Michigan Missouri California Massachusetts Wisconsin California Canada Missouri
1969 New York Maryland California Massachusetts New York Maryland Canada Missouri
1970 Maryland Ohio California New York Missouri Minnesota Massachusetts Missouri
1971 Pennsylvania Maryland Wisconsin Maryland Maryland Texas Canada Illinois
1972 California Ohio California New York Texas Florida Massachusetts New York
1973 California New York California New York Florida Washington D.C. Canada Illinois
1974 California California Wisconsin Massachusetts Florida Minnesota Pennsylvania Massachusetts
1975 Ohio Massachusetts California Washington D.C. Pennsylvania Minnesota Pennsylvania New York
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@stedy
stedy / Jerven_Table1.csv
Created June 12, 2016 03:00
Slopegraph of African GDP in R
Maddison Maddison Per capita GDP World Development Indicators WDI Per capita GDP Penn World Tables PWT Per capita GDP
Congo-Kinshasa 217 Congo-Kinshasa 92 Congo-Kinshasa 359
Sierra Leone 410 Ethiopia 115 Liberia 472
Chad 429 Burundi 139 Sierra Leone 684
Niger 486 Sierra Leone 153 Burundi 699
Burundi 496 Malawi 169 Ethiopia 725
Tanzania 535 Tanzania 190 Guinea-Bissau 762
Guinea 572 Liberia 191 Niger 867
Central African Rep. 576 Mozambique 191 Tanzania 817
Comoro Islands 581 Niger 200 Togo 823
library(dplyr)
raw_data <- read.csv("https://s3.amazonaws.com/pix-media/Data+for+TreefortBnB+Puzzle.csv") %>%
mutate(City = tolower(City))
simpleCap <- function(x) {
s <- strsplit(x, " ")[[1]]
paste(toupper(substring(s, 1, 1)), substring(s, 2),
sep = "", collapse = " ")
}
var http = require('http');
http.createServer(function (request, response) {
response.writeHead(200, {'Content-Type': 'text/plain'});
response.end('Hello from the server!');
}).listen(8008);
console.log('Hello from the command line!');
#solution to question posed here: http://simplystatistics.org/2015/11/25/a-thanksgiving-dplyr-rubiks-cube-puzzle-for-you
library(dplyr)
df <- read.table("https://gist.githubusercontent.com/jtleek/aae1218a8f4d1220e07d/raw/26fb7b5e485f7b9d66406179079a9d6f9418d544/puzzle_nov25_2015.delim",
header=T) %>%
mutate(rank=c(1,3,2,4)) %>%
arrange(rank) %>%
select(col1, col3, col2)