The fact that Lydia uses a weapon that is far weaker than her sword says different to your affirmation I highlighted here. Her bow and sword are exponentially more powerful than the staves she carries for me, but she uses them all interchangeably in battle. I see tactics more than preference.
You didn't read my post to the end. And some of the Staves may look weak but are, in fact, much stronger than you give them credit for - a sword that does 30 damage per hit has nothing on a Staff that does 8 DPS.
They do, of course, use tactics. They use ranged attacks when appropriate and melee when they can. I've even had Lydia try to raise corpses with a staff I gave her (but since this was at lvl 20 the staff was too weak). But this doesn't change the fact that they will use usually the best weapon they have (for what it's worth, Housecarls have both One-Handed
and Archery so they are equally skilled with the bow and 1h).
That said, what they equip does bug out sometimes. My Lydia sometimes fires off a couple of shots with her Ebony Bow before switching to her default Hunter's Bow. There was also a period, after she was disarmed by a Draugr, when she couldn't figure out
what weapon to use and literally equipped something different in every fight until I took everything off her and gave it all back.