When measuring the roughness of a machined surface, RA is the arithmetic average roughness which calculates the average deviation from a mean line, and RZ is is the mean roughness depth, which averages the distance from the highest peak to the lowest valley over a given interval. RA is the most common measurement for machined surfaces.
The different measurements for machined surfaces help universalize roughness measurements across industries. RA is the most common measurement and allows for quick accepting or rejecting of surfaces. More advanced measurements, such as RZ, allow for different measurements of specific criteria that are important for some industries but maybe not others.