I still think NBC is making a hell of mistake of taking off Jay Leno when he is still winning his time slot.
But ratings do not equal profit when you are paying your star WAY more than he's worth.
A lot of people bitched when Star Trek: Enterprise was cancelled despite having better ratings than Veronica Mars, which was renewed.
However, Veronica Mars cost a lot less to produce, so it was a more profitable show despite having lower ratings than Enterprise.