If you invest in the caravans via the Merchant Empire quest, the caravans are by far the richest - they will stock between 500 and 1200 caps each (roughly). Most other merchants top out at less than 500, although Moira Brown can apparently go as high as 3,000. (The Wikia mentions this but gives no details).
That said, as you (and commenters) have noted, trading for caps is generally a losing proposition - trade for other stuff instead, and use caps to make up the difference. Zero-weight items work best, so that you don't become encumbered. Bonus points if they're actually useful.