Looking at instruments from their specs, the piano sounds like it should be optimal: it has a huge range, the keys keep you in tune, you can play multiple notes at once, and each note requires little effort. Why doesn't everyone play the piano? Well, it's heavy and can only sound like a string instrument, but there are good keyboards now that are light and can sound like anything you want: why do we still have so many other instruments?

The problem with the piano or keyboard is that you've traded off a lot of expressiveness for capability. A pianist can choose how hard to hit a key, which changes how the string sounds when it is struck, but that's really it. [1] A violinist, however, can control the vibration of the string continuously, being much closer to directly manipulating it.

This is a tradeoff we see all over the place: a concertina is easier and faster to play than a harmonica, but it has limited control over the sound. The penny whistle and flute, harpsicord and the harp, bombarde and bagpipe; they all follow this pattern. People didn't stop playing the violin after the invention of keyed fiddles, and not just because they're complex and expensive: the farther you get from directly manipulating the sound, the more control you give up and the more your sound is limited. [2]

Seeing this relationship eveywhere, I decided to make some charts. They show, for a kind of instrument, what possibilities there are as you make different tradeoffs on complexity, cost, automation, and capablity. Consider the free reeds:

The jaw harp player, while limited to a single note, has incredible options for percussion and harmonic shapings. The harmonica trades off some of these options for many more notes, while retaining some control over how each note sounds. With the melodica we give up even that texture control, but get something much easier to play.

I made a few more:

The idea is that each instrument is categorized as branching off another that had the musician closer to the creation of the sound. As I made it, however, I realised that some branches added capabiltities without any real tradeoffs (bugle to trumpet). So this doesn't explain everything.

The full set, including others I didn't draw:

Update 2013-11-19: The viola organista is another instrument that belongs on this chart. It's a bowed string instrument, where pitch is chosen by selecting from among appropriately tuned strings. It should probably go under the bowed psaltery.

[1] This is reflected in MIDI: a note is defined as a note (0-127) and a velocity (0-127), followed by, some time later, an 'end of note' command. (There are also aftertouch, channel pressure, and pitch bend messages, but your standard midi keyboard doesn't generate them.)

[2] This sounds negative, but I don't mean it that way. The tradeoffs can be good ones: I like that my mandolin has frets because it makes chords much more practical to play in tune. I use a pick because I can play much faster. I like my penny whistle because I'ven't learned how to shape my mouth to play flute.