Add missing functionality from old repo

@stevengj I deleted the old repo to avoid confusion for users, this is all the old functionality ported to this repo
Probably use `# ... ` rather than multiline comments, for Julia 0.2 compatibility.