Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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
L = L*(eye(dim) + h/6*(feval(J,t,y,params)+2*feval(J,t+h/2,y+h/2*s1,params)*(eye(dim)+h/2*feval(J,t,y,params))+2*feval(J,t+h/2,y+h/2*s2,params)*(eye(dim)+h/2*feval(J,t+h/2,y+h/2*s1,params))*(eye(dim)+h/2*feval(J,t,y,params))+feval(J,t+h,y+h*s3,params)*(eye(dim)+h*feval(J,t+h/2,y+h/2*s2,params))*(eye(dim)+h/2*feval(J,t+h/2,y+h/2*s1,params))*(eye(dim)+h/2*feval(J,t,y,params)))); | |
%% BETTER | |
L1 = feval(J,t,y,params); | |
L2 = feval(J,t+h/2,y+h/2*s1,params)*(eye(dim)+h/2*L1); | |
L3 = feval(J,t+h/2,y+h/2*s2,params)*(eye(dim)+h/2*L2); | |
L4 = feval(J,t+h,y+h*s3,params)*(eye(dim)+h*L3); | |
L = L*(eye(dim) + h/6*(L1 + 2*L2 + 2*L3 + L4)); |
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
# index | |
phantom-crowbar http://hedonometer.org/index.html timeseries $(gdate +%Y-%m-%d -d "today")/index-timeseries.svg | |
phantom-crowbar http://hedonometer.org/index.html?date=$(gdate +%Y-%m-%d -d "yesterday") modalsvg $(gdate +%Y-%m-%d -d "today")/index-shift.svg | |
# books | |
phantom-crowbar http://hedonometer.org/books.html?book=frankenstein booktimeseriessvg $(gdate +%Y-%m-%d -d "today")/books-timeseries-frankenstein.svg | |
phantom-crowbar http://hedonometer.org/books.html?book=frankenstein shiftsvg $(gdate +%Y-%m-%d -d "today")/books-shift-frankenstein.svg | |
# us maps | |
phantom-crowbar http://hedonometer.org/maps.html?time=Last%207%20Days mapsvg $(gdate +%Y-%m-%d -d "today")/maps-map.svg |
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 PARAM in 1 5 10 15 | |
do | |
mkdir results_of_lda_${PARAM} | |
./lda est 1 ${PARAM} settings.txt sandyCorpus3.txt random ./results_of_lda_${PARAM} | |
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
for corpus in 0 1 2 3 4 5 6 7 8 9 a b c d e f g h i j k l m n o other p pos punctuation q r s t u v w x y z | |
do | |
wget http://storage.googleapis.com/books/ngrams/books/googlebooks-eng-all-1gram-20120701-${corpus}.gz | |
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
# self.data is a tuple of 2 items | |
# the first is trie for the non-regex (fixed) words | |
# and the second for the regex (stem) words | |
# matching on prefix mimins the [a-z]* match for the stems | |
# also, this was stolen from an internal function, so | |
# wordDict is a hash (dict) or "word": count | |
# for a corpus being scores | |
totalcount = 0 | |
totalscore = 0.0 |
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 X in {1..10} | |
do | |
for Y in 1 2 3 4 5 6 7 8 9 10 | |
do | |
echo "${X} ${Y}" | |
done | |
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
header.entry-header { | |
display: table; | |
padding-bottom: 20px; | |
} | |
header.entry-header:before { | |
content: url(https://wildflowerstudiobtv.files.wordpress.com/2015/03/flower.png?w=778); | |
display: table-cell; | |
vertical-align: middle; | |
} |
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
# make a file, call it backupcron.cron | |
# make sure it's executable (chmod +x backupcron.cron) | |
# put just this line in it | |
crontab -l > /users/a/r/areagan/crontab.out |
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
import os | |
import datetime | |
if __name__ == '__main__': | |
for file in os.listdir('.'): | |
if not file == 'flowify.py': | |
t = os.path.getmtime(file) | |
d = datetime.datetime.fromtimestamp(t) | |
if not os.path.isdir(d.strftime('/Users/andyreagan/flow/%Y/%m')): | |
os.mkdir(d.strftime('/Users/andyreagan/flow/%Y/%m')) |
OlderNewer