updated documentation for sorting