On the 737, I can make the cabin as hot as I want to; the challenge is more often adequate cooling if the aircraft got hot on the ground. With the insulation that the aircraft has, the generated heat of 100+ people in a confined space overwhelms the cooling of the outside air. (Yeah, it's utterly counter-intuitive, and I can't explain the why, but that is the way it goes. With the loss of all bleed air, the cabin will get hot -- although that's at 10,000', where you descended after the depressurization.)
I've never been told to run the temperature hot or cold as a fuel-saving measure. In theory, you save a little gas by not running the AC packs in "High", but again, that's mostly used to get more cooling air. Or to quickly warm a jet that sat unheated all night in freezing temperatures.
If the cabin was unbearably cold on a particular flight, somebody just wasn't attentive to the temperature. On any modern airliner, we have the tools to warm things up. Maybe the flight attendants prefered a cold cabin & had sweaters to wear; maybe "really cold" to the OP is actually pretty comfortable to others; maybe the thermostat was indicating erroneously high temperature in the cabin so the automatic system kept putting out cold air; or, maybe the pilots were being jerks and "freezing out" the flight attendants (and passengers) for some reason. Unlikely, that last, but not impossible or unheard of.
As far as a preference to run slightly warm or cool, cool will generally win, simply because warm tends to make airsickness worse, while cool has the opposite effect. On a bumpy flight, the last thing you want is a warm cabin; the saying goes that "popsicles don't puke," and it is accurate.