Both have advantages as well as disadvantages.
A mechanical gauge, you'll need to route the source or substance directly to the gauge to get a reading. So in the case of oil pressure or boost, you'll need to run tubing to the gauge itself. If the tubing were to crack or fail at our near the gauge, or the gauge fail itself, or anywhere for that matter, you'll have oil or gas or noxious engine air escaping into the drivers compartment or wherever the leak occurs.
The electrical setup, typically has a sending unit in some cases so the plumbing is either short or non existent. However, you have more failure points in the case of sending units and other electrical issues. And you have the headache of more wiring.
I tend to stay away from mechanical gauges now just because cleaning up things like oil in the car sucks or smelling the crankcase while the failed boost line is venting under the dash. Been there and done that. Lol
As for accuracy, I dunno what's better? But I'd pick electric any day.