code: def readcols(infile, cols=None):
      
      if _is_str_none(infile) is None:
          return None
  
      if infile.endswith('.fits'):
          outarr = read_FITS_cols(infile, cols=cols)
      else:
          outarr = read_ASCII_cols(infile, cols=cols)
      return outarr
docs: Function which reads specified columns from either FITS tables or
          ASCII files
  
          This function reads in the columns specified by the user into numpy
          arrays regardless of the format of the input table (ASCII or FITS
          table).
  
          Parameters
          ----------
          infile : string
              Filename of the input file
          cols   : string or list of strings
              Columns to be read into arrays
  
          Returns
          -------
          outarr : array
              Numpy array or arrays of columns from the table