

def sort_values(self, return_indexer=False, ascending=True):
    '\n        Return sorted copy of Index\n        '
    _as = self.argsort()
    if (not ascending):
        _as = _as[::(- 1)]
    sorted_index = self.take(_as)
    if return_indexer:
        return (sorted_index, _as)
    else:
        return sorted_index

dataset/ETHPy150Open pydata/pandas/pandas/indexes/base.py Index.sort_values/original