As usual there is no one size fits all and there are no magic buttons.
However, if you know for sure that you image indeed contained pure black and pure white (mathematically) then sure, go ahead.
Very often, you will have information in the color channels that the camera, or some other link in your chain, interpreted to be blacker than black and some that significantly whiter than white. If you color balance based on those extreme values in one or more of your color channels, then some other part of the tonal range of your image will become very unbalanced.
I would say that by the number approach has its plays but might not be valid in every situation.
Let’s say you have a sunset scene. If you were to balance shadows and highlights to be agsolutely neutral all the way through you would have lost the impression of the scene, as it would loose warmness of the original light.