Commander is the third HQ choice I will cover in my tactica articles. It is also the least complicated one, as Commanders are one of the simplest units to use.
A Commander, regardless of whether you pick a Captain or a Master, will have one main purpose in your army: to boost the Leadership of the entire army, via their special rule, Rites of Battle. Then, depending on what kind of war gear you give him, he will have another purpose: shooting or close combat.
Which "level" of Commander you pick will mostly depend on one thing: the number of Veteran Sergeants in the army. Obviously, if you have a Veteran Sergeant in every squad in your list, a Captain isn't something to consider - since the Leadership boost will be useless. In fact, a Master will be stretching it too if you have a Veteran Sergeant in all squads, since all squads will already have a pretty good Leadership, and you're probably better off with a Chaplain or a Librarian - since they have their own sets of sweet special rules and war gear.
A Commander is probably the best choice in a pretty shooty list with a set of static units such as Las/Plas Squads, Devastator Squads and similar - squads that usually don't have a Veteran Sergeant to lead them. Masters can work in other lists too, of course, but they are optimal in such lists.
The shooty/cheap variant:
One of the most popular set-ups for a Commander is to make him a Master, give him a Storm Bolter and sometimes a Power Sword and place him somewhere far back in your lines, where he is safe from both shooting and close combat (bar any Deep Striking units that is).
This Master - or Captain - will be one of the cheapest HQ-choices you can get as a Space Marine player, since Commanders have the lowest basic points cost of all. He doesn't get anything for free though - like the Chaplain and Librarian does, so you'll have to spend more points kitting him up.
The close combat/expensive variant:
Commanders can be quite effective in close combat, if given the right set of war gear, and some care when playing. The usual set-up looks like this:
Twin Lightning Claws
Jump Pack, Frag Grenades, Iron Halo
Right, so this guy gets five attacks on the charge, with good Initiative, good WS and S and a good Save. He'll also ignore armour saves and re-roll the failed to-wound dice.
He isn't a monster in close combat, so pick your enemy wisely. He should be attached to an Assault Squad no less than 8 men strong, with a Veteran Sergeant with a Power Fist and two Assault Marines armed with Plasma Pistols. The unit will be quite expensive, but well worth it if used with care.
This unit is best used in a static firepower list, since the Master is a Master after all, and used for counter-charging above anything else.
Since the Commander has access to pretty much the entire armoury, you can tool him up to do pretty much anything, and with any weapons of your choice. Keep in mind though, that the cheaper the better, and you need to have a specific role for the Commander, most of the times it's either Close Combat or Shooting.