Skip to content

Instantly share code, notes, and snippets.

@alexschell
alexschell / 0_reuse_code.js
Last active August 29, 2015 14:10
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@alexschell
alexschell / server.R
Last active August 29, 2015 14:05
Shiny app that displays time use trends for a custom set of tags from a TagTime log file
# Based on https://github.com/alexschell/misc-R/blob/master/tagtime_trends.R
# Example of the running app: http://alexschell.shinyapps.io/tagtime-trends/
require("httr")
ping.interval <- 45 # mean interval between pings in minutes (default 45)
tags <- c("prod3", "prod0", "proj", "auto", "school|class|hw",
"work", "slp", "drive", "social|im", "email|sms|phonecall",
"favor", "net", "tagtime|pfeedback", "outside|garden") # CHANGEME
# vector of tag names (or regular expressions) to plot trends of
# should correspond to elements in choices below