Year: 2005
Google Feed API
Google Feed API to be released soon. While on Google, there’s some rumour about Google Purchases being used for video rentals — and eventually on to micropayments, competing with Paypal. Also, William Slawski maps Google’s acquisitions.
Calvin and Hobbes index – 900602
My Calvin and Hobbes index is current up to June 1990.
Paul Graham on procrastination
Good and bad procrastination by Paul Graham.
The most impressive people I know are all terrible procrastinators. So could it be that procrastination isn’t always bad?
Why spaghetti does not break in half
Why spaghetti does not break in half. It usually breaks into three or more pieces. Audoly and Neukirch show several videos of this phenomenon. The also show that dry spaghetti breaks even if you just bend it, and release it suddenly. This is because the waves of curvature propogate through the spaghetti, and sometimes the curvature becomes too high. When you break spaghetti, it first breaks into two, and then the remaining halves behave as if they were released suddenly, splitting into further pieces.
Excel – Make your model visually obvious
Rule #4: Make your model visually obvious.
After years of creating Excel models with lots of inputs and lots of outputs, I’ve learnt two things.
Usually, only ONE input parameter matters. Think of this as being the constraint in the Theory of Constraints, or the principal component in factor analysis. You want your model to communicate the impact of the ONE parameter, and get a decision based on that. Keep the rest at their best default value.
Usually, only ONE output function matters. This is either a single number, or at most, a visually obvious function.
For example, I was working on creating an offshore test centre. The question was: what test activities should we outsource? I made a huge model evaluating 1,200 activities. A very elegant model. And totally incomprehensible. The issue really was simple. We could not recruit too fast. But at the same time, the more we offshore, the more the cost savings. So I built a summary sheet that showed the impact of one parameter (speed of ramp-up) on one function (offshore profile).
The fixed blue line shows the number of people required. The slider on the right ranges from “conservative ramp-up” to “aggressive ramp-up”. The green line shows how many resources will be offshore. In the conservative ramp-up, the recruitment rate is very manageable, but the saving is negligible, since hardly anyone is offshore. The aggressive ramp-up calls for an unmanageable ramp-up rate.
We showed the management this tradeoff. They said, “We can recruit 30 people next year”. That implied the moderate ramp-up scenario, and a cost saving of 27%. Total time spent in making decision: 2 minutes.
Creating a slider-based model is quite useful. You can download a US Treasury yields example to see how this is done. As you move the slider, the yield curve moves over time, showing how it has fluctuated. The trick is to:
- build the entire model based on a single cell. Cell H1 in this example acts as the index to the dates.
- create a slider. Go to View – Toolbars – Control Toolbox and add a slider.
- and link the slider to the cell. Right-click on the cell in design mode, select View Code, and type Range(“H1”).Value = ScrollBar1.Value in the Scrollbar change event.
Excel – Avoid manual labour 4
Debugging in Excel is another time consuming task. 80% of the trouble is identifying the problem (Error? What error? Where?) as opposed to fixing it (Why’s THAT cell showing THAT?). Most of my time is spent chasing three kinds of errors: wrong reference (leading to a #N/A or #REF!), wrong data input, or wrong formula.
Wrong references are easy to spot. You’ll see a #N/A or a #REF! sticking out. But on large sheets, even that’s tough to spot. I always have a SUM (or some kind of total) function that covers EVERY cell in EVERY table, even if I don’t need that information. If ther SUM shows a #N/A or #REF!, I can use Trace Error (Alt-T-U-E) to see where the problem is coming from.
If you know there’s a wrong reference in a cell (say A1), and want to ignore it, use a new cell with the formula =IF(ISERROR(A1),0,A1). You can substitute an entire row, column or table this way.
Wrong data input is best avoided upfront. Before I hand my Excel sheets over for large scale data entry, I do three things:
- Let them enter data only in input areas. Unprotect the cells the user can enter data in (Ctrl-1, Protection, remove the tick against ‘Locked’), and protect the whole sheet (Alt-T-P-P).
- Validate the data. Turn on data validation (Alt-D-L) on all editable cells, and specify the validation criteria.
- Make it easy to spot errors. If there are percentages that should add to 100%, show the total in a cell that turns green if the total is 100%, and red otherwise. (Use conditional formatting – Alt-O-D). If data about 20 people must be entered, show the number of people about whom data is entered, and mark it red until it’s 20. Make sure all criteria are captured. When the spreadsheet is filled, it should be impossible to make errors.
Wrong formulae (like + instead of -) are tough to spot. The best way to check for this is to do the same calculation in different ways, and compare the results. Whenever I create complex tables, I always have an error row at the bottom. I compare the totals on the table with the totals calculated in a simpler way and check the difference. This warns me when I miss out some elements, or double count something, in the table.
Excel – Avoid manual labour 5
A few tips, without getting into the details. Array formulas let you perform any calculation on an entire list, and get the result in a single formula. Database functions like DSUM can manipulate tables of data very flexibly. Using these and Pivot tables, you can do anything with any tabular data.