Skip to content

Instantly share code, notes, and snippets.

👔
Preparing TPS report cover pages

Peter Monks pmonks

👔
Preparing TPS report cover pages
  • San Francisco
Block or report user

Report or block pmonks

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@pmonks
pmonks / quil-radar-chart.clj
Last active Nov 19, 2018
quil-radar-chart.clj
View quil-radar-chart.clj
; Start a REPL with `lein try quil`, on JDK 1.8 (quil is not yet functional on JRE 9+)
(require '[quil.core :as q])
; Tunables (feel free to play with these)
(def window-size [1000 1000]) ; Initial size of the window
(def num-dimensions 9) ; Number of "dimensions" (spokes) to draw
(def num-circles 10) ; Number of circles in the chart
(def save-image (atom true)) ; Save the image (to a PNG) once, after it's first drawn
; Other constants (do not touch!)
@pmonks
pmonks / markov_fun.clj
Last active May 7, 2017
Little experiment with rm-hill/markov-chains to generate tweets
View markov_fun.clj
; Start a REPL with `lein try rm-hull/markov-chains`
(require '[markov-chains.core :as mc])
(require '[clojure.java.io :as io])
(require '[clojure.string :as s])
; tweets.txt should contain the text of your tweet archive, one tweet per line.
; To create this file, I:
; 1. exported my tweet history as per https://support.twitter.com/articles/20170160
; 2. imported the Twitter generated CSV into a Google Sheet
View keybase.md

Keybase proof

I hereby claim:

  • I am pmonks on github.
  • I am pmonks (https://keybase.io/pmonks) on keybase.
  • I have a public key ASCxXap2ro4H4RZvS9DP6oEMvE4uCx-z-eOCBZZj5aj5SQo

To claim this, I am signing this object:

View CMISSampleClient.groovy
/*
*
* Copyright © 2011-2016 Peter Monks (pmonks@gmail.com)
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
@pmonks
pmonks / queryTwitter.groovy
Created Sep 4, 2011
Groovy script that queries Twitter and formats the results into an HTML fragment
View queryTwitter.groovy
/****************************************************************************
* Copyright (c) Peter Monks 2010, 2011
* This work is licensed under a Creative Commons Attribution-ShareAlike
* 3.0 Unported License. See http://creativecommons.org/licenses/by-sa/3.0/
* for full details.
****************************************************************************/
@Grab(group="org.apache.commons", module="commons-lang3", version="3.1")
@Grab(group="org.slf4j", module="slf4j-api", version="1.6.4")
@Grab(group="ch.qos.logback", module="logback-core", version="1.0.1")
@Grab(group="org.twitter4j", module="twitter4j-core", version="2.2.5")
You can’t perform that action at this time.