nodes: 0, module; 1, function_definition; 2, function_name:arrange; 3, parameters; 4, block; 5, list_splat_pattern; 6, expression_statement; 7, expression_statement; 8, function_definition; 9, return_statement; 10, identifier:args; 11, comment:"""Sort DataFrame by the input column arguments.
  
    >>> diamonds >> sample_n(5) >> arrange(X.price) >> select(X.depth, X.price)
    Out:
           depth  price
    28547   61.0    675
    35132   59.1    889
    42526   61.3   1323
    3468    61.6   3392
    23829   62.0  11903
    """; 12, assignment; 13, function_name:f; 14, parameters; 15, block; 16, identifier:f; 17, identifier:names; 18, list_comprehension; 19, identifier:df; 20, expression_statement; 21, expression_statement; 22, return_statement; 23, attribute; 24, for_in_clause; 25, assignment; 26, assignment; 27, subscript; 28, identifier:column; 29, identifier:_name; 30, identifier:column; 31, identifier:args; 32, identifier:sortby_df; 33, binary_operator:df >> mutate(*args); 34, identifier:index; 35, attribute; 36, attribute; 37, identifier:index; 38, identifier:df; 39, call; 40, call; 41, identifier:index; 42, identifier:df; 43, identifier:loc; 44, identifier:mutate; 45, argument_list; 46, attribute; 47, argument_list; 48, list_splat; 49, identifier:sortby_df; 50, identifier:sort_values; 51, list_comprehension; 52, identifier:args; 53, call; 54, for_in_clause; 55, identifier:str; 56, argument_list; 57, identifier:arg; 58, identifier:args; 59, identifier:arg
code: def arrange(*args):
    """Sort DataFrame by the input column arguments.
  
    >>> diamonds >> sample_n(5) >> arrange(X.price) >> select(X.depth, X.price)
    Out:
           depth  price
    28547   61.0    675
    35132   59.1    889
    42526   61.3   1323
    3468    61.6   3392
    23829   62.0  11903
    """
    names = [column._name for column in args]
    def f(df):
      sortby_df = df >> mutate(*args)
      index = sortby_df.sort_values([str(arg) for arg in args]).index
      return df.loc[index]
    return f