sorting out the scale and axis elements