I bought this 400E several months ago, I replaced a bunch of parts as preventive maintenance: (distributor caps &rotors, spark plugs, fuel pressure regulator, engine oil filter, air filters, transmission fluid and filter), I didn't replace O2 sensors and Cat, they looked like new, I guess previous own must have already replaced them.
It did shake and idle roughly, now it's smooth like silk.
I replaced fuel pressure regulator and O2 sensors (it has 3 of them!!) on my other car: Ford explorer, before I replaced them, it blew black smoke and I got 10 mpg, now I get 16 mpg.
99 BMW 540i 6-speed 110K Km
03 SAAB 9-5 wagon 80K Km
92 400E (Sold) 245K km
Still missing the days with the Benz, it kept me busy.