Skip to content

Instantly share code, notes, and snippets.

View masnick's full-sized avatar

Max Masnick masnick

View GitHub Profile
@masnick
masnick / gist:7601046
Created November 22, 2013 14:47
A combination of the Correspondence and Thread Arcs layouts in MailMate.
{
name = "Correspondence Arc";
rootViewer =
{
viewerType = "MmSplitView";
orientation = "horizontal";
children =
(
{
viewerType = "MmBoxView";
The NPAR1WAY Procedure
Wilcoxon Scores (Rank Sums) for Variable fst
Classified by Variable markertype
Sum of Expected Std Dev Mean
markertype N Scores Under H0 Under H0 Score
──────────────────────────────────────────────────────────────────────────
DNA 6 60.50 63.0 12.115236 10.083333
protein 14 149.50 147.0 12.115236 10.678571
@masnick
masnick / SAS defaults.sas
Last active August 29, 2015 13:56
Sensible SAS defaults
dm 'odsresults; clear';; /* Clears results from Results bar every time you run this line. */
dm 'clear log'; /* Clear the log window every time you run this line. */
dm 'clear out'; /* Clear the output file every time you run this line. */
ods listing; /* Turn on old style output */
options nodate pageno=1 linesize=80 pagesize=60 source; /* Old style output display settings */

Keybase proof

I hereby claim:

  • I am masnick on github.
  • I am masnick (https://keybase.io/masnick) on keybase.
  • I have a public key whose fingerprint is B899 A28A 08DF ABEF F98F B8A6 DCCA 9E3F D712 5546

To claim this, I am signing this object:

-----BEGIN PGP MESSAGE-----
Version: GnuPG/MacGPG2 v2.0.22 (Darwin)
Comment: GPGTools - https://gpgtools.org
hQEMA8MeMF20Q5DgAQf+IVPiuUEeCPfE+vbJRfDxVavbb2g0oRg7VZJCAfXRnRcX
pOE6lDIQeJrpMkoXwVC/Ks8XTJGc+Z+MPFyBZxw/iKtuL/Ij2vjHjCIZT95k5gZf
W8m5tYmryRQLb2+haMtgLnPvx8JPAK/79TExmFwwEsnfemVJDgwlQoTpJNWSZ08Z
1uRjZKw4MTRAjN/67jKCNun1C7WT+rzPOulRmlDTevSxDF8RCzLCeBSSQS+rc/Mp
NxHRK4ZCKT0Ul1qC35/d0FjNN/DBreOXYE8nzCEAAhfuk1LGCJrHLjAyfa5b7mKS
yN8y9+nezcaykFysSinazBOCVvupe0UY0d2rJD7ySdLpAUvy7UbgQZNHhvOzaC18
@masnick
masnick / gist:9761488
Last active August 29, 2015 13:57
Beats feedback

I switched to Beats because the iPhone app is great, and the Rdio app (my previous music service) did not handle offline music well.

Unfortunately, I listen to most music through my computer, and the Beats web player is terrible. I know you're working on improving it, but some issues, like logging me out every 24 hours, are just bad design decisions. Little progress has been made on the web player since I signed up, and the current buggy player is too annoying to continue using.

Other issues with the web player:

  • Playback randomly cutting out, requiring a refresh to fix
  • Stopping and then resuming playback after more than a few minutes was very unreliable: clicking "play" wouldn't start the track again, and none of the play icons for other tracks would work. Refreshing was the only solution (and sometimes I'd be inexplicably logged out), and the app wasn't smart enough to remember what I was listening to so I'd have to manually navigate back to where I was.
  • Can't view library on web player
  • Requires Fl
@masnick
masnick / modified-zotselect-link.js
Last active November 13, 2023 08:16
Zotero export translator for getting zotero:// link and article information
@masnick
masnick / gist:d77d018be007acf9e97b
Last active November 11, 2015 20:01
AppleScript to set the "Play sound effects through" drop down in the Sound preferences on Mavericks
tell application "System Preferences"
activate
set current pane to pane "com.apple.preference.sound"
end tell
tell application "System Events"
tell application process "System Preferences"
-- Fix for El Capitan:
-- http://apple.stackexchange.com/questions/209352/applescript-cant-get-tab-group-1-of-window-el-capitan
repeat until exists tab group 1 of window "Sound"
@masnick
masnick / osx.bash
Created October 3, 2014 10:20
OS X preferences
#!/usr/bin/env bash
# ~/.osx — http://mths.be/osx
# Ask for the administrator password upfront
sudo -v
# Keep-alive: update existing `sudo` time stamp until `.osx` has finished
while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
@masnick
masnick / gist:380d067da1f521b01cb0
Last active December 17, 2017 19:24
Find FastMail tab(s) in Safari
-- original from http://hea-www.harvard.edu/~fine/OSX/safari-tabs.html
-- Last updated January 16, 2015 1:22 PM
set searchpat to "fastmail.com"
tell application "Safari"
activate
set winlist to every window
set winmatchlist to {}
set tabmatchlist to {}
set tabnamematchlist to {}