xlwings Newsletter #42

xlwings adds an ultra-fast Excel file reader!

Meet the New & Ultra Fast Excel File Reader!

xlwings v0.28.0 comes with an ultra-fast Excel file reader. Compared with

pandas.read_excel()

, you should be able to see speedups anywhere between 5 to 25 times when reading a single sheet. The exact speed will depend on your content, file format, and Python version. The following Excel file formats are supported:

  • xlsx / xlsm / xlam

  • xlsb

  • xls

Other advantages include:

  • Support for named ranges

  • Support for dynamic ranges via myrange.expand() or myrange.options(expand="table"), respectively.

  • Support for converters so you can read in ranges not just as pandas DataFrames, but also as NumPy arrays, lists, scalar values, dictionaries, etc.

  • You can read out cell errors like #DIV/0! or #N/A as strings instead of converting them all into NaN

Unlike the classic (“interactive”) use of xlwings that requires Excel to be installed, reading a file doesn’t depend on an installation of Excel and therefore works everywhere where Python runs. However, reading directly from a file requires the workbook to be saved before xlwings is able to pick up any changes.

While the file reader is part of xlwings PRO, it is free for non-commercial use! For more details, click the button to open the docs!

Thanks for reading along!~ Felix