This part is all in subjunctive mood/conditional, indicating the hypothetical:
the mean is where the histogram would balance, were it a solid object cut out of a uniform block of metal
meaning:
the mean is where the histogram would balance, if it [the histogram] were a solid object cut out of a uniform block of metal
or, less formal:
the mean is where the histogram would balance, if it [the histogram] would be a solid object cut out of a uniform block of metal
The "were it" subject-verb inversion devices replaces the "if" conditional construct.
"If it would be" is less formal, and some language boards consider it even incorrect/tolerated.