Fixed sorting and atom_export_array bug
proper auto-scale