Improved compatibility of the mda reading and fixed scaling.