In D&D 5e when you choose to buy equipment, do you take the starting equipment from your background (but not the starting equipment from the class), from neither the class nor the background, or is it the choice of the DM?
Neither, just the gold
PHB, pg. 143:
When you create your character, you receive equipment based on a combination of your class and background. Alternatively, you can start with a number of gold pieces based on your class and spend them on items from the lists in this chapter. See the Starting Wealth by Class table to determine how much gold you have to spend.
So RAW and RAI if you choose to buy your equipment you don't get any equipment from your class nor background. Ask your DM, however, since many houserule different starting equipment, specially above level 1.