Except for a small amount of base housing, most of the people who live on base are single E4 and below. They live in barracks without kitchens and eat in the galley.
Service members with families, by and large, live off base, and probably closer to a Walmart than a commissary.
The Air Force dorms at Edwards have kitchens...and those who can, choose to live on Edwards vs. facing at a minimum 40 mile RT commute everyday with gas at $4+ per gallon...
The nearest WM to Edwards is about 35 miles (1 way) away...
Partly true about families. Here in the DC area there are more families than there is housing. But even the folks who live off post use the commissaries. In Places where I served during my 20 years, it seemed the majority of the families lived on post. And as for shopping in walmart for groceries, I don’t know how well your Walmart is stocked for food, but here in the DC area the Walmart food aisles are about six in number and about 1/3rd of the store length long. I get a better selection of food by 300% at the commissary. I have seen a couple of the super-Walmart’s you are probably talking about, but they are in the Shendoah Valley of Virginia, a 2 hour drive west of the DC metro area. the nearest Walmart to me is farther than Andrews AFB, where I usually shop (I’m retired). the grocery section is smaller than the hardware area.