This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{- | |
:! ghc -c SmSn/Ripple.hs | |
:load SmSn/Ripple | |
SmSn.Ripple.main | |
Examples: | |
reduce 1 [Do, dup, string "foo"] | |
reduce 1 [Do, plus, int 2, int 3, int 42] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{- | |
:! ghc -c SmSn/Activity.hs | |
:load SmSn/Activity | |
SmSn.Activity.main | |
-} | |
module SmSn.Activity where | |
import SmSn.Bayesian |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{- | |
Prerequisites: | |
cabal install random | |
cabal install MonadRandom | |
cabal install split | |
Text, e.g.: | |
cat /Users/josh/copy/humor/douglas_adams/hhgttg/book1.txt | grep -v "=\|Chapter" | tr '\r\n\t\"' ' ' | sed 's/ */ /g' > /tmp/bayes-play.txt |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
* Synesthesia: A Union of the Senses | |
as book: | |
author: Richard E. Cytowic | |
chapter: Introduction | |
section: Historical Developments | |
note: | |
* the emotion-color synesthesia noted by Cytowic | |
* "Cytowic has found examples of people in whom extreme emotions can be the trigger, so that anger, kissing, or even orgasms can release shapes, textures, or colors" | |
section: Criticism of Experiential Responses | |
section: Synesthetes as Cognitive Fossils |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
children: | |
- | |
id: foobar | |
- | |
id: quuxly | |
created: 1487976536438 | |
id: jrWpedhT8hjABdhJ | |
text: |- | |
This is multiline text. | |
Newlines are escaped. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for file in `find . -name "*.smsn"`; do echo $file" "$(grep -c "\`\`\`" $file); done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
ls | grep "^................$" > /tmp/files | |
for i in `cat /tmp/files`; do git mv $i $i.smsn; done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@id 11111 | |
@title Arthur Dent | |
@created 1501437598535 | |
* :oSxwi4mCUd8Oqq3Y: | |
* :t57BnfhEfUjzgWKi: | |
@text ``` | |
He's a jerk. | |
A complete kneebiter. | |
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# | |
# Set up a directory for generating SmSn/SmSn-mode wiki documentation. | |
# | |
# After running this Bash script, you can run the Haskell scripts, e.g. | |
# runghc smsn-mode/smsn-to-git-markdown.hs ~/smsn+/input.auto.md | |
mkdir smsn-md | |
cd smsn-md/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Bash | |
FILE=art.mm | |
cat $FILE | grep CREATED|sed 's/.*CREATED..//' | sed 's/\".*//' | sort -u > /tmp/timestamps.csv | |
# export your graph with C-c C-w v, then: | |
cat /tmp/smsn-vertices.tsv | tr '\t' '_' | sed 's/_/,/' | sed 's/_.*//' > /tmp/timestamp-and-id.csv | |
R | |
timestamps <- read.csv(file("/tmp/timestamps.csv"), header=FALSE)$V1 |
NewerOlder