Skip to content

Instantly share code, notes, and snippets.

View emckean's full-sized avatar
💭
have I told you about Wordnik?

Erin McKean emckean

💭
have I told you about Wordnik?
View GitHub Profile
require 'wordnik'
%w(rubygems wordnik).each {|lib| require lib}
Wordnik.configure do |config|
config.api_key = ''
config.response_format = 'xml'
end
#unless ARGV.length == 2
/Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/response.rb:21:in `initialize': message (ClientError)
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:173:in `new'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:173:in `make'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:177:in `response'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/resource_modules/word_list.rb:84:in `get_word_list_by_id'
from single-list-test.rb:17:in `<main>'
/Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/response.rb:21:in `initialize': user does not have access to word list 1 (ClientError)
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:173:in `new'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:173:in `make'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/request.rb:177:in `response'
from /Users/emckean/.rvm/gems/ruby-1.9.2-p180/gems/wordnik-4.06.10/lib/wordnik/resource_modules/word_list.rb:138:in `get_word_list_words'
from puborprivlists.rb:25:in `block in <main>'
from puborprivlists.rb:18:in `collect'
from puborprivlists.rb:18:in `each'
from puborprivlists.rb:18:in `<main>'
bailor
bailout
bailout bond
bait and switch
bait record
balance protection
balance reporting
balance sheet
balance sheet reserves
balanced anova
@emckean
emckean / gist:1335322
Created November 2, 2011 23:43
clean wsj glossary list 11/2
-DI
"Made whole" doctrine
+DI
1031 exchange
1035 exchange
1040 EZ
1098 form
1099
1099-B
1099-B Form
@emckean
emckean / gist:1355916
Created November 10, 2011 19:37
canonical forms
401(k) 401(k) plan
403(b) 403(b) plan
American depositary receipt American Depositary Receipt
American Institute Of Certified Public Accountants American Institute of Certified Public Accountants
ARB arb
automated bond system Automated Bond System
BA Ba
Board Of Directors board of directors
Bollinger bands Bollinger Bands
book runner bookrunner
@emckean
emckean / gist:1375383
Created November 18, 2011 02:23 — forked from kumanan/gist:1375379
glossary_words_with_examples
200-day moving average
401(k) plan
529 plan
A
ADVANCE
ALPHA
ARBITRAGE
ASK
AWAY
Abandon
%w(rubygems wordnik).each {|lib| require lib}
Wordnik.configure do |config|
config.api_key = 'YOUR_KEY_HERE'
end
result = Wordnik.words.get_frequency('judgement')
print result
@emckean
emckean / gist:2919470
Created June 12, 2012 19:06
Discovery Lunch Contest Rules
-- come to the discovery lunch with something cool you found on "teh internets" or in Real Life
-- be prepared to explain how you found it (esp if you found it someplace embarrassing, like how Thomas finds all his great gluten-free recipes on the Esperanto Haiku Yodeling forums ... )
-- we'll all vote on the best/funniest/coolest/most useful discovery (each week's category is a secret until the beginning of lunch) and the winner will get a PRIZE, over and above bragging rights.
@emckean
emckean / gist:2925372
Created June 13, 2012 17:26
randomizr rememberr
1.9.3p125 :001 > wordniks = ["ramesh", "robert", "tony", "..."]
=> ["ramesh", "robert", "tony", "..."]
1.9.3p125 :002 > randomniks = wordniks.shuffle
=> ["ramesh", "tony", "robert", "..."]
1.9.3p125 :003 > half = randomniks.length/2
=> 2
1.9.3p125 :004 > teama = randomniks.slice(0, half)
=> ["ramesh", "tony"]
1.9.3p125 :005 > teamb = randomniks.slice(half, randomniks.length)
=> ["robert", "..."]