Skip to content

Instantly share code, notes, and snippets.

View zkamvar's full-sized avatar
🍄
On Sabbatical

Zhian N. Kamvar zkamvar

🍄
On Sabbatical
View GitHub Profile
@johnslemmer
johnslemmer / index.html
Last active June 9, 2022 17:45
Wordle (copy of source code on 2022.01.31 just in case the NYTimes fucks it up)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no" />
<title>Wordle - A daily word game</title>
<meta name="description" content="Guess the hidden word in 6 tries. A new puzzle is available each day.">
<!-- FB Meta Tags -->
@emilyriederer
emilyriederer / ugliest-ggplot-theme.R
Last active May 11, 2023 06:35
A very, very ugly ggplot2 to demonstrate the wide variety of ggplot2 theme() options
library(ggplot2)
# sample data for plot ----
points <-
data.frame(
x = rep(1:10,3),
y = rep(1:10,3),
z = sort(rep(letters[1:2], 15)),
w = rep(letters[3:4], 15)
)
# ggplot using many theme options ----
@brodieG
brodieG / cran-check.R
Last active June 18, 2019 21:02
Check CRAN Results
# started with `foghorn`, but that comes with dependencies and
# slows down R startup. `browseURL` just barely slows startup,
# even if actual page is slow to load.
check_cran_old <- function(email) {
utils::browseURL(
sprintf(
"https://cran.r-project.org/web/checks/check_results_%s.html",
gsub("[^A-Za-z0-9_:.-]", "_", sub("@", "_at_", email))
) ) }
<!doctype html>
<!-- This is just a very slightly modified tracking.js demo: https://trackingjs.com/examples/face_camera.html -->
<html>
<head>
<meta charset="utf-8">
<script src="https://cdnjs.cloudflare.com/ajax/libs/tracking.js/1.1.3/tracking-min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/tracking.js/1.1.3/data/face-min.js"></script>
<style>
video, canvas {
margin-left: 100px;
@joshkatz
joshkatz / sotu.R
Created January 31, 2018 15:49
State of the Union WPM chart
needs(rvest, tidyverse, zoo)
df <- c('minutes', 'words') %>%
map(function(var) {
doc <- var %>%
sprintf(fmt = 'http://www.presidency.ucsb.edu/sou_%s.php') %>%
read_html()
doc %>%
html_node('table tr:nth-of-type(2) table') %>%
html_table(fill = T) %>%
@junioryauricasa
junioryauricasa / index.html
Created December 9, 2017 19:14
table style css - Tablas estilo EXCEL
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<link rel="stylesheet" type="text/css" href="excel-2000.css"/>
<link rel="stylesheet" type="text/css" href="excel-xp.css"/>
<link rel="stylesheet" type="text/css" href="excel-2003.css"/>
<link rel="stylesheet" type="text/css" href="excel-2007.css"/>
<script lang="javascript">
@ericclemmons
ericclemmons / example.md
Last active February 22, 2024 16:18
HTML5 <details> in GitHub

Using <details> in GitHub

Suppose you're opening an issue and there's a lot noisey logs that may be useful.

Rather than wrecking readability, wrap it in a <details> tag!

<details>
 Summary Goes Here
@bastman
bastman / docker-cleanup-resources.md
Created March 31, 2016 05:55
docker cleanup guide: containers, images, volumes, networks

Docker - How to cleanup (unused) resources

Once in a while, you may need to cleanup resources (containers, volumes, images, networks) ...

delete volumes

// see: https://github.com/chadoe/docker-cleanup-volumes

$ docker volume rm $(docker volume ls -qf dangling=true)

$ docker volume ls -qf dangling=true | xargs -r docker volume rm