pyexcel_io.iget_data

pyexcel_io.iget_data(afile, file_type=None, **keywords)[source]

Get data from an excel file source

The data has not gone into memory yet. If you use dedicated partial read plugins, such as pyexcel-xlsxr, pyexcel-odsr, you will notice the memory consumption drop when you work with big files.

Parameters:
  • afile – a file name, a file stream or actual content

  • sheet_name – the name of the sheet to be loaded

  • sheet_index – the index of the sheet to be loaded

  • sheets – a list of sheet to be loaded

  • file_type – used only when filename is not a physical file name

  • force_file_type – used only when filename refers to a physical file and it is intended to open it as forced file type.

  • library – explicitly name a library for use. e.g. library=’pyexcel-ods’

  • auto_detect_float – defaults to True

  • auto_detect_int – defaults to True

  • auto_detect_datetime – defaults to True

  • ignore_infinity – defaults to True

  • ignore_nan_text – various forms of ‘NaN’, ‘nan’ are ignored

  • default_float_nan – choose one form of ‘NaN’, ‘nan’

  • pep_0515_off – turn off pep 0515. default to True.

  • keep_trailing_empty_cells – keep trailing columns. default to False

  • keywords – any other library specific parameters

Returns:

an ordered dictionary