code: def idxmax(self, **kwargs):
          
          if self._is_transposed:
              kwargs["axis"] = kwargs.get("axis", 0) ^ 1
              return self.transpose().idxmax(**kwargs)
  
          axis = kwargs.get("axis", 0)
          index = self.index if axis == 0 else self.columns
  
          def idxmax_builder(df, **kwargs):
              if axis == 0:
                  df.index = index
              else:
                  df.columns = index
              return df.idxmax(**kwargs)
  
          func = self._build_mapreduce_func(idxmax_builder, **kwargs)
          return self._full_axis_reduce(axis, func)
docs: Returns the first occurrence of the maximum over requested axis.
  
          Returns:
              A new QueryCompiler object containing the maximum of each column or axis.