How UCLA PhD candidate used machine learning to find true love


Just before Chris Mckinley earned his PhD in mathematics from UCLA, he was on a quest for love.  Like millions of others on that quest, he turned to the aid of dating sites.  After countless failed matches and little to no prospects he turned to his skills to help him do the heavy lifting.  Mickinley’s research as a PhD candidate focused on large-scale data processing and parallel numerical methods.  Knowing that one of the dating sites became famous for their mathematical approach to matching couples, he created a few python scripts to data mine potential matches that were more suited to his him that what the site was matching him with.  Using a clustering algorithm based on one developed by Bell Labs (previously used to analyze diseased soybean crops) called K-modes, he was able to reverse-engineer how the dating site weighted the questions it asks each person to gauge how well they match with another.  With this data in hand, McKinley then used a machine-learning called adaptive boosting to weight his own answers to these questions to better match himself with suitors that more accurately fit who he’d like to meet.  Needless to say, his mathematics brought him a fairytale ending.

Found on: Wired.

Stop junking up your .hosts file

*, there's no place like

I hate having to constantly manage my .hosts file. Even with the PrefPane helpers, POW, an the countless other tools for linking your development application to your browser. Thankfully, there’s lacolhost. I can finally sleep at night without dreading starting up a new project.

All it takes is a nice visit to, and it will redirect right back to my localhost. Now I can test my app with subdomains without having to create the link for it every time. Awesomeness.

[experiment] Timeline.js – Revolutionary User Interfaces

This is an example of Timeline.js displaying the change of user interfaces over time.

[Rails] How to install Thoughtbot’s Suspenders

Suspenders by Thoughtbot

I’m a HUGE fan of the team over at Thoughtbot. I’ve been looking over a couple different Rails templates as a means to speed up new project setups, so I decided to try on their Suspenders.

Unfortunately, following their installation instructions may get you to where I was: Nowhere Land.  I kept getting these wonderful error messages anytime I would create a new project:

fatal: remote error:   Could not find Repository thoughtbot/suspenders-gem

From the code, it appears the trout file was trying to checkout from their old repository. Their latest code on master seems to be the best place for updates, so a quick fix was to just build the gem from there (code found in the Rakefile):

git clone git://
cd suspenders
mkdir -p pkg
gem build suspenders.gemspec
mv suspenders-.gem pkg
cd pkg
gem install suspenders-.gem

I use RVM (as you should too), and before I performed this I switched to my 1.9.2@rails3.1 gem set that I use in the directory that I start in for all my projects. Something you may want to consider as well.

Booom! Suspenders in full force! Enjoy.

Learn to Code Interactively with Codecademy



When it comes to learning how to program, let’s face it: Learning by example is best.  The greatest tools I’ve used to learn a new language have always revolved around some sort of Interactive Environment.  From Ruby’s IRB to PHP’s Interactive Shell.  Heck, Python’s interpreter uses one by default!

Codecademy has learned this fact as well, and has brought to the masses one of the greatest tools to just plain learn how to code.  They’ve combined the interactive shell with good ‘ol fashioned competition.  Using their site, you can not only track your progress, but you can compare your progress to your friends; and make sure you blow them out of the water 😉

Add the Rails console to your browser!

Rack/Rails web-console

Rails web console

[UPDATE]:  Please note, this gem is for DEVELOPMENT PURPOSES ONLY.  Do not use in production.

I came across an awesome gem today: rack-webconsole.  As the name suggests, it adds the rails console to your browser!  No more switching back and forth between the terminal.  This gem is awesome!  This has to be the easiest installation too.  Just add this line to your Gemfile:

gem 'rack-webconsole'

Once you’ve bundled:

bundle install

Just restart your web server and you’re up and running.  Bingo!  Unity.

If you really don’t understand how useful this is, then you really need to read the Secrets of the Rails Console Ninjas.

Zerply comes out of beta – what they learned

Zerply Infographic #2 - beta stage

Zerply beta stage

Zerply, an awesome “new” service to get a quick professional profile, recently released an infographic with some pretty cool statistics they gathered from their pre-release beta phase.  According to their study:

  • 10,879 users joined during the private beta
  • 77% of users stuck through to the public release
  • Sundays were lame for signups
  • People generally signed up during the middle of the week.  Especially on a Thursday.
  • 40% of beta user signups were viral (users inviting users via Twitter and Facebook)
  • The top services people listed were: 1. twitter, 2. facebook, 3. linkedin, 4. skype

Awesome stuff!  A tip of the old hat for you Zerply.  Check me out.

[facebook] How to add all friends to an event

So you’re on Facebook, you’ve created a new event, filled out all the details, and you click the button to invite all your friends. Oh wait, there is no “add all friends” button! Those user-interface Nazis over at Facebook make you slave over the pain of clicking on each and every one of your 800 friends.

Well my friends, Nazis never win. Using your favorite JavaScript console (I used the one that comes with Google Chrome), you can copy & paste the below code to select all your friends.*

* before you enter the below code, you have to first go to edit the event, and click on the button to invite your friends. When the window with a list of your friends pops up, open your JavaScript console and enter the following:

// First get the container with all your friends
var friends = document.getElementById('all_friends');

// Now we go through and select each friend
for(var i=0; i < friends.childNodes.length; i++) {[i]); }

Bam! Just like that, your friends were selected. Well, depending on how fast your computer is, or how many friends you have, you might need to wait up to 30 sec. For the script to run.

Enjoy the freedom 🙂

[AS3] ImageScroll v1.0

Get Adobe Flash player

This movie showcases the ImageScroll class I created to allow large media to fit in smaller, more manageable spaces. You simply provide it with a DisplayObject to use as the mask for the image, and load it when your ready. It will automatically take care of loading the image, and will apply scrolling capabilities as soon as it’s finished. The image will stay it’s actual size and will scroll based on the mask’s dimensions.