Tuesday, May 28, 2013

2013 Monaco Grand Prix Finishing Position vs. 2013 Driver Salary

I've only watched a few Formula One races, but I did manage to catch this weekend's Grand Prix de Monaco. Beautiful and exciting race, and only about 100 minutes long for those with things to do.

I did a quick regression on finishing position vs. 2013 driver salary. It's only one race, so there's bound to be some discrepancies (there were a couple accidents and one engine fire). However, the correlation is still quite moderate (R=0.613) andit makes the case for a more egalitarian approach to driver salaries. Alas: there's more to racing than just one race, and more to racing than, well: racing.

To note: one would expect a fairly strong downward-sloping curve if drivers were paid based on the results of just this one race.

I'll do another regression on 2013 World Series final results vs. salary.

Salary data (via Reddit) courtesy of Crash.net.



And when you log the salaries:




The best fit, as one may expect, is exponential:




Sunday, February 17, 2013

Video: A Case for Open Data in Transit

As a user of open data from the MBTA (I'm a big fan of NextBus), I can't agree more with the movement towards opening as much data as possible to developers for urban transit initiatives. If done right, it encourages expanded ridership and can serve to make the services more efficient.

I think O'Reilly's point in the video of government serving as a platform for private development is startlingly obvious and insightful.


Saturday, February 9, 2013

The Restaurant Service Auction Market

A recent story about a cheap pastor in St. Louis who got an Applebee’s server fired for uploading a copy of the pastor’s receipt (the pastor didn’t like the mandatory 18% tip for a group of 6, so she stiffed the server citing religious reasons) got me thinking about the Principal-Agent Problem again. I won’t dwell on it too much, but two quick things: 

First off, the obvious: doesn’t 10% seem a little low for a pastor? Why bother giving that figure, anyway? 

Secondly, punishing the server for a (disclosed and commonly applied) mandatory tip is a textbook example of the perils of the Principal-Agent Problem in the food service industry. The pastor should have gone directly to the manager to complain about the policy, but decided to take it out on the lowly server.

The fact that a religious figure was involved is a large part of why this story got out, but the fact of the matter is: the pastor should have taken out her frustration in another manner. It’s not like people blame her for bad weather events (a.k.a. Acts of God), right? 

Anyway, this sort of customer behavior can be avoided through a market approach. That is why, if I were to open a restaurant, I’d try something like this: 

  • All tips are set at a minimum of 15% and are pooled among all restaurant staff and there is no cap (i.e. a customer could bid for a 100% tip if they so desired)
  • Additional preferred treatment can be arranged by bidding (in units of % of the bill as total tip), such as: 
    • Personal food/drink recommendations
    • Faster service (this would be automatically controlled by the kitchen and bar – servers may game the system by holding up orders to appear like service to other tables is faster; customers can bid on when their meals or drinks come out) 
      • The estimated time of arrival of the meal or drink must be known to the customer for transparency. 
    • Requests for special occasions (birthdays, engagements, etc.) 
  • Customers are held to their promised tip amount unless the promised service at the time of the bid is not met (e.g. the food arrives a few minutes late) 
  • The price for a “bid for preferential treatment” is based on supply and demand. For instance, if it’s a busy Friday night with lots of people bidding, a 1% increase in tip won’t get you to the top of the list. 
    • Customers would only know if there is someone ahead of them and will be told by the system the current price (in % of tip) of a bid for a given request 
    • Someone who does not bid must be guaranteed some reasonable level of service. You might think of this as the “floor.” 
  • Standard quality must be maintained no matter how "rushed" a customer wants their food. This gets tricky if people want their food to be cooked faster than good quality would allow. This would need to be factored into resource constraints when telling the customer how quickly the food can be delivered to their table.


I'm not sure how well it would work (i.e. how long I'd stay in business), but it would be a good dining experiment.

Friday, November 9, 2012

Data Crunching, Election Edition

I'm getting more into data analytics, and have been looking for some substantial examples beyond the usual "more and more companies are using analytics" blanket statements from Harvard Business Review. Much to my relief, Time came out with a nice piece about the Obama campaign's use of data in their recent electoral victory.

Full disclosure: I'm a libertarian and was in the 1% of the population that voted for Gary Johnson. Living in Massachusetts, my vote didn't matter anyway. I also voted for Scott Brown for Senate because he is a moderate, though his campaign was poorly managed.

Anyway, the article points out some interesting bits about how the Obama campaign pulled off the win. Through massive computer simulations, data crunching, targeted ads, and efficient door-knocking, they were able to raise $1 billion. That is impressive no matter how you spin it, folks. One can only imagine what upcoming local elections will have.

I have a friend who works in the (spinning down post-election) Elizabeth Warren campaign. He's more on the database-building-mechanics side of things, but he was able to talk about how the campaign used the data to target individual voters. My bet: the scale of analytics used in this year's national election (per voter) will be used at the local level in 2-4 years.

Monday, November 5, 2012

Delivery Time Improvement Auction Market

In high school and during college breaks, I worked at a local pizza place (as I've mentioned all too frequently here). As an overzealous engineering student, I was always looking for ways to do things more efficiently. One of our biggest problems: inefficient allocation of human capital (a.k.a. delivery boys).

Alas, I never had the time to come up with anything fancy, until now (years later). I decided to start a pet project to develop a web-based "Pizza Delivery Route Optimizer" using as much open source software as possible.

I'm still designing the system, and don't plan on selling it, but a thought occurred to me:

What if people could bid in a live auction on how quickly their orders could arrive? Let's say it's a busy Friday night, and you want your pizza there in 30 minutes or less. In a fair world, even with a fancy Pizza Delivery Route Optimizer running, this would be an unrealistic expectation.

But what if it weren't? What if you could see approximately when your order would arrive, how many orders were ahead of you, and could either bid against other orders to move up in the pecking order or pay a small fee to do the same? What would be a fair price? I'd imagine it would be tailored to current supply (number of drivers) and demand (number of orders). For example, if there are 20 orders ahead of you and only 15 drivers on staff, the fee would be higher than it would be if there were 10 orders and 12 drivers.

To do an auction, the customer would need to set up an account and would only be billed if their expected (not actual) delivery time were made earlier. It'd be unfair to the delivery guy (and probably unsafe) to guarantee a time of arrival. Remember Domino's "30 Minute Guarantee"? Domino's ended it when a delivery guy killed someone trying to make it in the 30 minute window.

I think there may be a market for the auction format, but the implementation would be tough. For one, you wouldn't likely have people stay on a website to actually bid in real time (they are, after all, not willing to spend the time picking the pizza up in the first place). Therefore, a simple fee would probably be easier to implement. This would, however, not necessarily do well for the delivery guy, since the customer would feel no reason to tip the delivery guy if they've already paid more for the delivery in the first place. Perhaps you could split the fee with the delivery guy? It's a tough one to do if you want things to be fair to all parties.

Monday, October 29, 2012

2012 MLB Dollars Per Win

With the San Francisco Giants' sweep of the Detroit Tigers last night, the 2012 MLB Season is officially in the books.

As I've done the past few years, I broke things down in simple terms: which teams were the most efficient in getting the most value per dollar in payroll? Yes, this isn't really a straightforward answer, since teams with higher payrolls tend to have higher non-baseball revenues (namely merchandising and TV deals), but from a pure baseball standpoint: who had the best year?

Below is a simple table of how teams ended up in terms of dollars in payroll vs. total wins (including post-season). The Oakland Athletics, a perennially efficient team, did extremely well this year, spending nearly one fifth as much per win as the lowly Red Sox. Not to be forgotten was the sub-par performance of the Phillies this season.




Source for payroll amounts: http://www.cbssports.com/mlb/salaries

The World Series Champion San Francisco Giants ended up in the middle of the pack due to their above average payroll, though one could argue winning it all is worth it. I would also credit the Washington Nationals for being the only other 100 win team while having a below average payroll; great year for the Natinals.

Just for your edification, here is the correlation between wins and payroll this year. Note how low R^2 is: 0.053. I'd have to look at other years, but this year turned out to be quite a year of parity.